30.10.2013, 10:25
Having a little issue while trying to insert some data.
Code
Problem
Code
pawn Код:
format(qq,sizeof(qq),"INSERT INTO `atm_data` (AtmExists,Charge,ATM_X,ATM_Y,ATM_Z,ATM_Rot_X,ATM_Rot_Y,ATM_Rot_Z) VALUES ('1','5','%f','%f','%f','%f','%f','%f')",x,y,z,rx,ry,rz);
mysql_query(qq);
mysql_free_result();
pawn Код:
[10:33:11] >> mysql_query( Connection handle: 1 )
[10:33:11] CMySQLHandler::Query(SELECT * FROM `atm_data`) - Successfully executed.
[10:33:11] >> mysql_store_result( Connection handle: 1 )
[10:33:11] CMySQLHandler::StoreResult() - Result was stored.
[10:33:11] >> mysql_num_rows( Connection handle: 1 )
[10:33:11] CMySQLHandler::NumRows() - Returned 1 row(s)
[10:33:11] >> mysql_fetch_row_format( Connection handle: 1 )
[10:33:11] CMySQLHandler::FetchRow() - Return: 1|1|7|15.4374|1186.98|19.1082|0|0|90
[10:33:11] >> mysql_fetch_row_format( Connection handle: 1 )
[10:33:30] >> mysql_query( Connection handle: 1 )
[10:33:30] CMySQLHandler::Query(INSERT INTO `atm_data` (AtmExists,Charge,ATM_X,ATM_Y,ATM_Z,ATM_Rot_X,ATM_Rot_Y,ATM_Rot_Z) VALUES ('1','5','19.256700','1191.1) - 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 ''1191.1' at line 1)
[10:33:30] >> mysql_free_result( Connection handle: 1 )
[10:33:30] CMySQLHandler::FreeResult() - Result was successfully free'd.