Posted: 25th May 2007 18:01
I think the ODBC driver for windows and mysql can be found on the mysql site, iirc. That may be the problem he's having.
Posted: 25th May 2007 18:58
well I didn't know how to use the myspl_setconnection, thats wht i was asking and I bet that was my problem lemme try it out.
i guess u can call me a n00b at sql cuz i really am lol

+ Code Snippet
mysql_init
test = mysql_setconnection ("DRIVER={MySQL ODBC 3.51 Driver};server=http://sql1.byethost7.com;uid=b7_611319;pwd=**********;database=b7_611319_accounts")
if test=1
print "Connection Successful"
else
print "Connection Failed"
endif
wait key


It's going a lot further now, the command works now but I'm still having problems connecting with a server. is http://sql1.byethost7.com the right format?



any ideas?
Posted: 25th May 2007 19:39
I don't think you use "http://"

it's just the domain name, ip address, or localhost
Posted: 25th May 2007 19:51
Your webhost probably does not allow mysql connections from random ip addresses by default. You may be able to configure it but many hosts do not allow remote connections at all or limit them to a small number of ip addresses.

I don't think mysql is really suited to this task.

Users have to download and install MySQL ODBC drivers.
Cheap webhosts often don't allow unrestricted remote mysql access.
User name and pass can be sniffed enabling users to connect with another mysql client and run their own queries.
All the logic is client side so users have to download a new version to get bug fixes.

I'd use something on the server like php that would sit between the dbpro app and the database. Then use this code snippet to make http requests to the php files and get the response.
http://forum.thegamecreators.com/?m=forum_view&t=106091&b=6

Bug fixes / improvements that just effect the server don't need the user to download a new version.
No secret info hidden in the exe the user can exploit. They just have their user name + pass.
No additional drivers/libraries need to be installed.
Server code can check what the client is doing, no increasing their score by 10,000 points or tampering with other users data.
Posted: 25th May 2007 20:02
The way I have mine setup is

Client <-> Server <-> MySQL

a database is ideal for 1000s of player files. (I currently have 21,317 player LUA files on another server I run so I decided it's a database for sure this time!)
users don't have to download any drivers
it can't be sniffed unless they break into my house
the client cannot alter didly pip
if you run your own MySQL you can have as much access and space as you like
Posted: 25th May 2007 21:40
thanks to everyone above posting all this info. I might add that if you dont have the odbc driver installed but you are calling it in the conncetion string, that could also cause a problem. also there may be different version numbers, youd need to check the one you have and the one your calling. It was 3.51 when I developed the plugin but I havent looked at it since then so I cant say if they have had updates.
Posted: 27th May 2007 8:17
You have your own server? thats too much for me but if anyone knows a free sql host that does allow unrestricted remote mysql access?

oh and winch, you mean like I access php pages with the app and then the php can access mysql? wouldn't that be a bit slow?
Posted: 27th May 2007 10:16
The sql server runs as windows service.. So it really isnt slowing u or something because u dont see the server app anywhere.. But u can choose when u install sql server do u want to run it as windows service or as application..

My system uses sql in client too temporatilty
but i will change it to client <-> server <-> mysql
Posted: 27th May 2007 15:25
If it runs as a service it means it is available all the time running in the background no matter what.

If you run it as an application it will only run while a user is logged in which means if your server has a power failure and reboots it won't start the SQL server until the user logs back in and runs it!
Posted: 27th May 2007 21:33
ok ill run it as a service, I thought that was on windows server 2003 tho....

How do i install it on xp home?
Posted: 27th May 2007 22:03
Just select the service option at install time. it seems to work for me. I also run an apache and perl server too. The only think you can't do on home is password protecting files. But you can setup apache to take care of this if you need it.
Posted: 29th May 2007 21:03
U dont really need to run apache and perl server too.. they are just needed to web server.. (I just use Apache and Mysql and PHP) But if u want to watch out ur sql database then i suggest running apache and php in it.. (Makes SQL Table creation easier and etc..) Because myphpadmin
Posted: 24th Jun 2007 2:39
I dont have a windows xp install cd...
Posted: 24th Jun 2007 2:45
They all come in Linux version too

In fact if you get a server distro it will probably install them all for ya

If you don;t wana mess about with servers you could just use LUA files.
Posted: 25th Jun 2007 6:39
what? wold ubuntu work? and is there a way to install it on say a flash card? so that I dont have to overwrite windows xp
Posted: 25th Jun 2007 6:42
wait no i can't use linux, dbpro doesn't work on linux...

how do I install the server thing on windows xp without reinstalling windows xp?

edit: actually, ill try apache, I had trouble installing it before though
Posted: 25th Jun 2007 6:50
You can install linux on 1 PC and XP on another. You need 2 PCs though

Unbuntu is like a dead easy version of Linux. i don't think it will fit on a flash card. Something like DSL (Damn Small Linux) would and if you got the VM version it would work as a virtual machine from inside windows but it is slow emulated like that.

I think you best bet if you don't know what your doing is to use something like LUA scripting. I have a server running that has like 16,000+ player files and it's just text files.
Posted: 25th Jun 2007 16:36
ok i got the linux part

wouldn't text files make it a bit slow?

I'll look into LUA scripting
Posted: 25th Jun 2007 20:15
The only problem I have with LUA text files is the way Windows XP shows files in it's directories. To scroll though 16000 player files is hard.

I use Perl scripts to calculate high scores and such and it don't seem too bad speedwise so I guess it's just a problem at the GUI level.

A database is the fastest solution and is what I'm gona use for my new games player files. But i'm still gona use LUA for stuff like object and monster lists as editing a text file in notpad is easier than changing values in a database for this purpose.
Posted: 25th Jun 2007 20:46
can't you just open up the directory in firefox or something and make it easier to view? at least you dont have that slow scrolling thing that keeps jumping and such.

So do I need to run the sql server as a service? or can I just get another sql server?

and where do you get the perl server?

I'm prolly gonna follo ur footsteps a lil of the way but eventually I'll go a different path. If you don't mind, at least you can help a lil.


edit: oh and what all do I need for lua? like just a compiler and editor or is there more?