Guten Tag,
Meine Sql Lite Query will nichtmehr:
format(mainquery,sizeof(mainquery),"INSERT INTO `SpielerFahrzeugen` (`ID`, `PosX`, `PosY`, `PosZ`, `PosA`, `Besitzer`, `vehiclemodel`, `Preis`, `Spoiler`, `Hood`, `Roof`, `Sideskirt`, `Lamps`, `Nitro`, `Exhaust`, `Wheels`, `Stereo`, `Hydraulics`, `FrontBumper`, `RearBumper`, `VentRight`, `VentLeft`, `paintjob`, `Color1`, `Color2`) VALUES ('%i','%f','%f','%f','%f','%s','%i','%i',",id,x,y,z,a,owner,model,price);
format(query,sizeof(query),"'0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0')");
strcat(mainquery,query);
print(mainquery);
db_query(Database,query);
Im Serverlog steht es so:
[21:21:32] INSERT INTO `SpielerFahrzeugen` (`ID`, `PosX`, `PosY`, `PosZ`, `PosA`, `Besitzer`, `vehiclemodel`, `Preis`, `Spoiler`, `Hood`, `Roof`, `Sideskirt`, `Lamps`, `Nitro`, `Exhaust`, `Wheels`, `Stereo`, `Hydraulics`, `FrontBumper`, `RearBumper`, `VentRight`, `VentLeft`, `paintjob`, `Color1`, `Color2`) VALUES ('0','1546.137817','-1684.413818','6.102824','89.030723','Marvin','405','50','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0')
Rechtschreibfehler finde ich keine.
Meine Tabelle sieht so aus:
CREATE TABLE "SpielerFahrzeugen" (
"ID" INTEGER,
"PosX" float(11),
"PosY" float(11),
"PosZ" float(11),
"PosA" float(11),
"vehiclemodel" INTEGER,
"Besitzer" TEXT(24),
"Preis" INTEGER,
"paintjob" INTEGER,
"Color1" INTEGER,
"Color2" INTEGER,
"Spoiler" INTEGER,
"Hood" INTEGER,
"Roof" INTEGER,
"Sideskirt" INTEGER,
"Lamps" INTEGER,
"Nitro" INTEGER,
"Exhaust" INTEGER,
"Wheels" INTEGER,
"Stereo" INTEGER,
"Hydraulics" INTEGER,
"FrontBumper" INTEGER,
"RearBumper" INTEGER,
"VentRight" INTEGER,
"VentLeft" INTEGER,
PRIMARY KEY ("ID" ASC)
);
Alles anzeigen