MySQL Console errors - 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 Console errors (
/showthread.php?tid=347732)
MySQL Console errors -
BleverCastard - 02.06.2012
Ok, so If I join my gamemode and quit, I get this console error:
Код:
Error #1064 - Error: 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 ' = '0', Interior = 0, Skin = 147 WHERE ID = 6' at line 1 | Query: UPDATE players SET Health = '100.000000', Armour = '0.000000', Gamemaster = '0', Score = '0', Cash, = '0', Interior = 0, Skin = 147 WHERE ID = 6
Here is the lines:
Код:
format(szQuery, sizeof(szQuery), "UPDATE players SET Health = '%f', Armour = '%f', Gamemaster = '%d', Score = '%d', Cash, = '%d'", playerVariables[playerid][pHealth], playerVariables[playerid][pArmour], playerVariables[playerid][pGamemaster], playerVariables[playerid][pScore], playerVariables[playerid][pCash]);
format(szQuery, sizeof(szQuery), "%s, Interior = %d, Skin = %d WHERE ID = %d", szQuery, playerVariables[playerid][pInterior], playerVariables[playerid][pSkin], playerVariables[playerid][pDBID]);
Re: MySQL Console errors -
Ricop522 - 03.06.2012
You have a "," on Cash
, Cash, = '%d
See?