08.03.2014, 11:40
Hi,
I'm trying to do my house system and I have this to insert into the database, but when it tries to, it doesn't insert the data and I have this Error in mysql_log.
So this is what I'm trying to insert:
How could I solve this problem please ?
Thank you !
I'm trying to do my house system and I have this to insert into the database, but when it tries to, it doesn't insert the data and I have this Error in mysql_log.
Код:
[13:30:22] [DEBUG] mysql_format - connection: 1, len: 1024, format: "INSERT INTO `maisons` (`Proprietaire`, `Prix`, `Ouverte`,`Achetee`, `Location`, `PrixLocation`, `NombreLocataire`, `Coffre`, `en..." [13:30:22] [DEBUG] mysql_tquery - connection: 1, query: "INSERT INTO `maisons` (`Proprietaire`, `Prix`, `Ouverte`,`Achete", callback: "(null)", format: "(null)" [13:30:22] [DEBUG] CMySQLQuery::Execute[] - starting query execution [13:30:22] [ERROR] CMySQLQuery::Execute[] - (error #1136) Column count doesn't match value count at row 1
Код:
mysql_format(mysql, query, sizeof(query), "INSERT INTO `maisons` (`Proprietaire`, `Prix`, `Ouverte`,`Achetee`, `Location`, `PrixLocation`, `NombreLocataire`, `Coffre`, `entreeX` ,`entreeY`, `entreeZ`, `sortieX`, `sortieY`, `sortieZ`, `Interieur`, `World`, `Arme1`, `Munition1`, `Arme2`, `Munition2`,`Arme3`, `Munition3`) VALUES ('%s', '%d', '%d', '%d', '%d', '%d', '%d', '%d', '%f', '%f', '%f', '%f', '%f', '%f', '%d', '%d', '%d', '%d', '%d', '%d', '%d', '%d', '%d')", "Ville de Los Santos", mInfo[id][mPrix], mInfo[id][mOuverte], mInfo[id][mAchetee], mInfo[id][mLocation], mInfo[id][mPrixLocation], mInfo[id][mNombreLocataire], mInfo[id][mCoffre], mInfo[id][mEntreeX], mInfo[id][mEntreeY], mInfo[id][mEntreeZ], mInfo[id][mSortieX], mInfo[id][mSortieY], mInfo[id][mSortieZ], mInfo[id][mInterieur], mInfo[id][mWorld], mInfo[id][mModele], 0, 0, 0, 0, 0, 0); mysql_tquery(mysql, query, "", "");
Thank you !