14.11.2012, 12:31
Hi, I just converted my script to MySQL and i have a little problem with an query.
Error Code:
Code:
Witch can be the problem ?
Error Code:
Код:
[15:46:52] 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 'Name`, `IP`, `Time`, `Reason`, `Date`, `Admin`, `Expire`, `Code`} VALUES ('sHapp' at line 1, OnQueryFinish, INSERT INTO `bans_ip (`Name`, `IP`, `Time`, `Reason`, `Date`, `Admin`, `Expire`, `Code`} VALUES ('sHapp3z0r', '192.168.0.100', '2', 'Reclama', '14/11/2012 la 15:46:52', 'Server/Anticheat', '2012/11/16 la 15:46:52', '2012,11,16,15,46,52'), 1
Код:
format(query, sizeof(query), "INSERT INTO `"#MYSQL_BANSIPTABLE" (`Name`, `IP`, `Time`, `Reason`, `Date`, `Admin`, \ `Expire`, `Code`} VALUES ('%s', '%s', '%d', '%s', '%s', '%s', '%s', '%s')", GetName(playerid), PlayerIP(playerid), time, reason2, string, admin, expiredate, expire); mysql_query(query, -1, -1, 1);