Simple MySQL reading crashes the Server - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Simple MySQL reading crashes the Server (
/showthread.php?tid=98258)
Simple MySQL reading crashes the Server -
virtualmarc - 19.09.2009
Hello,
I made a simple reading from a MySQL Database, but if I output this, the server crashes:
pawn Code:
new chkqry[255]
format(chkqry,sizeof(chkqry),"SELECT * FROM user WHERE name='%s'", plname);
samp_mysql_query(chkqry);
samp_mysql_store_result();
new money[255];
new line[1024];
samp_mysql_fetch_row(line);
new SpDv[30][50];
split(line, SpDv, '|');
new ausg[255];
format(ausg,sizeof(ausg),"Wert: %s",SpDv[5]);
Does someone know if I made something wrong or is it something other?
Re: Simple MySQL reading crashes the Server -
westre - 19.09.2009
Outputs to console.
Re: Simple MySQL reading crashes the Server -
virtualmarc - 19.09.2009
yes I know. I want it in the console! I only forgot to copy this line!
And this is the output:
Re: Simple MySQL reading crashes the Server -
virtualmarc - 20.09.2009
ok unter Linux (I started it on my root-server) theres no problem.
It only crashes on windows!
Re: Simple MySQL reading crashes the Server -
Andom - 20.09.2009
Did you forget to change 'localhost' ?