[Problem] SQL , Server crashes -
Dj_maryo1993 - 29.08.2009
After a few hours ,i "instaled" the myqsol on an normal gf , but i have the next problem : When i attemp to /login into the account , the server crashes
pawn Код:
if (strcmp(cmd, "/login", true) ==0 )
{
if(IsPlayerConnected(playerid))
{
new tmppass[64];
if(gPlayerLogged[playerid] == 1)
{
SendClientMessage(playerid, TEAM_AZTECAS_COLOR, "SERVER: You are already logged in.");
return 1;
}
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, TEAM_AZTECAS_COLOR, "USAGE: /login [password]");
return 1;
}
strmid(tmppass, tmp, 0, strlen(cmdtext), 255);
//Encrypt(tmppass);
OnPlayerLogin(playerid,tmppass);
}
return 1;
}
The /register works fine , but the login doesn't

.
Please help , i need this as soon as possibile
Or if you have an tutorial how to instal myqsol db on normal script i will apriciate.
Re: [Problem] SQL , Server crashes -
mirkoiz - 29.08.2009
Edit:Sorry,

Cookie hasnt read
Re: [Problem] SQL , Server crashes -
Dj_maryo1993 - 29.08.2009
http://pastebin.com/m73f1623
Ps It was in the first post too
Re: [Problem] SQL , Server crashes -
mirkoiz - 29.08.2009
pawn Код:
samp_mysql_strtok(Field, "|", Data);
while (samp_mysql_strtok(Field, "|", "")==1)
shouldnt it be
pawn Код:
samp_mysql_strtok(Field, ",", Data);
while (samp_mysql_strtok(Field, ",")==1)
Re: [Problem] SQL , Server crashes -
Dj_maryo1993 - 29.08.2009
pawn Код:
while (samp_mysql_strtok(Field, ",")==1)
Number of arguments doesn't mach the definition
Re: [Problem] SQL , Server crashes -
Dj_maryo1993 - 30.08.2009
Bump!
Re: [Problem] SQL , Server crashes -
MenaceX^ - 30.08.2009
Read forum rules.
Quote:
|
Originally Posted by ►☺◄©ookie►☺◄
pawn Код:
samp_mysql_strtok(Field, "|", Data); while (samp_mysql_strtok(Field, "|", "")==1)
shouldnt it be
pawn Код:
samp_mysql_strtok(Field, ",", Data); while (samp_mysql_strtok(Field, ",")==1)
|
Quote:
|
Originally Posted by Dj_maryo1993
pawn Код:
while (samp_mysql_strtok(Field, ",")==1)
Number of arguments doesn't mach the definition
|
wtf?.. There is a | between fields, not a ",".. This is so stupid, you better stay away from this topic.
Where's the OnPlayerLogin code?
Re: [Problem] SQL , Server crashes -
Dj_maryo1993 - 30.08.2009
http://pastebin.com/m73f1623
It was in the first post too

.
Re: [Problem] SQL , Server crashes -
Dj_maryo1993 - 30.08.2009
Com-on , it's gotta be someone that had instaled the myqsol on gf
Re: [Problem] SQL , Server crashes -
Dj_maryo1993 - 30.08.2009
Srry for 3xpost
Код:
Error in mysql_query: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'Char=0,ContractTime=0 WHERE id=0' at line 1