28.04.2018, 02:58
Hey guys. I'm trying to create a function to create a garage. However I keep getting the same error and I'm probably being super blonde but I can't find the bloody error.
The error I'm getting is
Here is my mysql code
Would really appreciate anyone who puts time into replying and trying to help me out.
The error I'm getting is
Код:
(error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '` = 0, `GarageOwner` = '-', `GaragePosX` = 248.198, `GaragePosY` = -1361.403, `G' at line 1
Код HTML:
new query[2024]; mysql_format(g_iHandle, query, sizeof(query), "INSERT INTO `garages` SET hID` = %d, `GarageOwner` = '%s', `GaragePosX` = %f, `GaragePosY` = %f, `GaragePosZ` = %f, `GaragePosA` = %f, `GarageIntX` = %f,`GarageIntY` = %f, `GarageIntZ` = %f, `GarageIntA` = %f, `VirtualWorld` = %d, `Interior` = %d, `Status` = %d, `ForSale` = %d, `Price` = %d WHERE `gID`=%d", GarageInfo[id][hID], GarageInfo[id][GarageOwner], GarageInfo[id][ExtX], GarageInfo[id][ExtY], GarageInfo[id][ExtZ], GarageInfo[id][ExtA], GarageInfo[id][IntX], GarageInfo[id][IntY], GarageInfo[id][IntZ], GarageInfo[id][IntA], GarageInfo[id][vWorld], GarageInfo[id][IntID], GarageInfo[id][Status], GarageInfo[id][ForSale], GarageInfo[id][Price], id); mysql_tquery(g_iHandle, query, "OnGarageCreated", "i", id);