07.11.2010, 13:34
(
Последний раз редактировалось ajwar; 07.11.2010 в 13:56.
)
What may be the problem? I get this:
[14:15:26] CMySQLHandler::Query(UPDATE `vehicles`(Owner, X, Y, Z, Angle,Spa,Spa1,Fuel,Uzr,Apz,Tune0,Tune1,Tune2,Tune 3,Tune4,Tune5,Tune6,Tune7,Tune8,Tune9,Tune10,Tune1 1,Tune12,Tune13) VALUES(liol, 2112.217529, 1402.398559, 11.167914, 217.859771, 12, 42, 10, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0)) - 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 '(Owner, X, Y, Z, Angle,Spa,Spa,Fuel,Uzr,Apz,Tune0,Tune1,Tune2,T' at line 1)
I use this:
[14:15:26] CMySQLHandler::Query(UPDATE `vehicles`(Owner, X, Y, Z, Angle,Spa,Spa1,Fuel,Uzr,Apz,Tune0,Tune1,Tune2,Tune 3,Tune4,Tune5,Tune6,Tune7,Tune8,Tune9,Tune10,Tune1 1,Tune12,Tune13) VALUES(liol, 2112.217529, 1402.398559, 11.167914, 217.859771, 12, 42, 10, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0)) - 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 '(Owner, X, Y, Z, Angle,Spa,Spa,Fuel,Uzr,Apz,Tune0,Tune1,Tune2,T' at line 1)
I use this:
pawn Код:
format(Query, sizeof(Query), "UPDATE `vehicles`\
(Owner, X, Y, Z, Angle,Spa,Spa1,Fuel,Uzr,Apz,Tune0,Tune1,Tune2,Tune3,Tune4,Tune5,Tune6,Tune7,Tune8,Tune9,Tune10,Tune11,Tune12,Tune13) \
VALUES(%s, %f, %f, %f, %f, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d)",
vInfo[vehicleid][Owner],
PositionX,
PositionY,
PositionZ,
AngleZ,
Color1,
Color2,
vInfo[vehicleid][Fuel],
vInfo[vehicleid][Uzr],
vInfo[vehicleid][Apz],
GetVehicleComponentInSlot(vehicleid, CARMODTYPE_SPOILER),
GetVehicleComponentInSlot(vehicleid, CARMODTYPE_HOOD),
GetVehicleComponentInSlot(vehicleid, CARMODTYPE_ROOF),
GetVehicleComponentInSlot(vehicleid, CARMODTYPE_SIDESKIRT),
GetVehicleComponentInSlot(vehicleid, CARMODTYPE_LAMPS),
GetVehicleComponentInSlot(vehicleid, CARMODTYPE_NITRO),
GetVehicleComponentInSlot(vehicleid, CARMODTYPE_EXHAUST),
GetVehicleComponentInSlot(vehicleid, CARMODTYPE_WHEELS),
GetVehicleComponentInSlot(vehicleid, CARMODTYPE_STEREO),
GetVehicleComponentInSlot(vehicleid, CARMODTYPE_HYDRAULICS),
GetVehicleComponentInSlot(vehicleid, CARMODTYPE_FRONT_BUMPER),
GetVehicleComponentInSlot(vehicleid, CARMODTYPE_REAR_BUMPER),
GetVehicleComponentInSlot(vehicleid, CARMODTYPE_VENT_RIGHT),
GetVehicleComponentInSlot(vehicleid, CARMODTYPE_VENT_LEFT)
);