Mysql not saving - 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)
+--- Thread: Mysql not saving (
/showthread.php?tid=548403)
Mysql not saving -
lutherfchen - 29.11.2014
forward GuardarCuenta(playerid);
public GuardarCuenta(playerid)
{
if(IsPlayerConnected(playerid))
{
new string[1024];
format(string, sizeof(string), "UPDATE `usuarios` SET `password`='%s', `Correo`='%s', `Sexo`=%d, `Admin`=%d, `Faccion`=%d, `Rango`=%d, `Radio`=%d, `MP3`=%d, `PoliceDuty`=%d, `LR`='%d' WHERE `username`='%s'", \
Pass[playerid], Correo[playerid], Sexo[playerid], Admin[playerid], Faccion[playerid], Rango[playerid], Radio[playerid], MP3[playerid], PoliceDuty[playerid], LR[playerid], nombre(playerid));
mysql_query(mysql, string);
mysql_free_result();
}
return 1;
}
Re: Mysql not saving -
Raweresh - 29.11.2014
Delete:
Код:
mysql_free_result();
And show mysql logs.
Re: Mysql not saving -
sammp - 29.11.2014
pawn Код:
format(string, sizeof(string), "UPDATE `usuarios` SET `password` = '%s', `Correo` = '%s', `Sexo` = '%d', `Admin` = '%d`, `Faccion` = '%d', `Rango` = '%d', `Radio` = '%d', `MP3` = '%d', `PoliceDuty` = '%d', `LR` = '%d' WHERE `username` = '%s'", definitions here);