Lirbo

Untitled

May 27th, 2017
137
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 0.94 KB | None | 0 0
  1. stock SaveAccount(playerid)
  2. {
  3.     new query[128], Cache:result, store[256];
  4.     mysql_format(sql, query, sizeof query, "UPDATE `Accounts` SET "); strcat(store, query);
  5.     mysql_format(sql, query, sizeof query, "`Money` = %d ",DB[playerid][Money]); strcat(store, query);
  6.     mysql_format(sql, query, sizeof query, "`Faction` = %d ",DB[playerid][Money]); strcat(store, query);
  7.     mysql_format(sql, query, sizeof query, "WHERE `Name` = '%s'", PlayerName(playerid)); strcat(store, query);
  8.     result = mysql_query(sql, store);
  9.     cache_delete(result);
  10. }
  11.  
  12. [15:49:40 05/27/17] [ERROR] CMySQLQuery::Execute - (error #1064) 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 '`Faction` = 0 WHERE `Name` = 'Lirbo4'' at line 1 (Query: "UPDATE `Accounts` SET `Money` = 0`Faction` = 0 WHERE `Name` = 'Lirbo4'")
  13. [15:49:40 05/27/17] [WARNING] CMySQLHandle::DeleteSavedResult - invalid result id ('0')
Advertisement
Add Comment
Please, Sign In to add comment