SA-MP Forums Archive
Mysql INSERT INTO Error - 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 INSERT INTO Error (/showthread.php?tid=374319)



Mysql INSERT INTO Error - Larry123 - 02.09.2012

Hello, This is my code:


Код:
	format(sql, sizeof(sql), "INSERT INTO `business` (`Name`, `Owned`, `Owner`, `PickupX`, `PickupY`, `PickupZ`, `Price`) VALUES ('%s', 0, 0, '%f', '%f', '%f', '%d')",
	name, pX, pY, pZ, price);
	mysql_query(sql);
And this is my debug file:

[18:14:44] CMySQLHandler::Query(INSERT INTO `business` (`Name`, `Owned`, `Owner`, `PickupX`, `PickupY`, `PickupZ`, `Price`) VALUES ('test', 0, 0, '1815.4399) - An error has occured. (Error ID: 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 ''1815.4399' at line 1)


Where is the problem, i can`t find.
Thanks


Re: Mysql INSERT INTO Error - Larry123 - 02.09.2012

Fixed