18.02.2012, 08:32
There is no reason to select anything from accounts. Only update label.
Also, for 1561515631 time, All Table and COlumn names put between grave ( ` ) so it doesn't mix with SQL Syntax.
pawn Код:
format(query,sizeof(query),"UPDATE `accounts` SET `AdminLevel` = '%d',`vip` = '%d',`Member` = '%d',`Leader` = '%d',`Genre` = '%d',`Saveskin` = '%d',`Pot` = '%d',\
`Crack` = '%d',`Hours` = '%d',`Minutes` = '%d',`Bank` = '%d',`Level` = '%d',`CarLicense` = '%d',`Achievement` = '%d',`Fishingrod` = '%d',`Fishingline` = '%d',`Fishingbaits` = '%d',\
`Cig` = '%d',`Lighter` = '%d',`Soda` = '%d',`Bag` = '%d',`Civilskin` = '%d',`Ipod` = '%d',`Job` = '%d',`Glasses` = '%d',`President` = '%d',`FStyle` = '%d',`Guard` = '%d',`OwnBus` = '%d',\
`OwnBusID` = '%d',`Cell` = '%d',`Radio` = '%d',`Number` = '%d',`Passport` = '%d' WHERE `Name` = '%s'", PlayerData[playerid][AdminLevel],PlayerData[playerid][vip],PlayerData[playerid][Member],
PlayerData[playerid][Leader],PlayerData[playerid][Genre],PlayerData[playerid][Saveskin],PlayerData[playerid][Pot],PlayerData[playerid][Crack],PlayerData[playerid][Hours],PlayerData[playerid][Minutes],PlayerData[playerid][Bank],GetPlayerScore(playerid),PlayerData[playerid][CarLicense],PlayerData[playerid][Achievement],
PlayerData[playerid][Fishingrod],PlayerData[playerid][Fishingline],PlayerData[playerid][Fishingbaits],PlayerData[playerid][Cig],PlayerData[playerid][Lighter],PlayerData[playerid][Soda],PlayerData[playerid][Bag],PlayerData[playerid][Civilskin],PlayerData[playerid][Ipod],PlayerData[playerid][Job],PlayerData[playerid][Glasses],PlayerData[playerid][President],PlayerData[playerid][FStyle],PlayerData[playerid][Guard],PlayerData[playerid][OwnBus],PlayerData[playerid][OwnBusID],
PlayerData[playerid][Cell],PlayerData[playerid][Radio],PlayerData[playerid][Number],PlayerData[playerid][Passport],pname);
mysql_query(query);
format(query,sizeof(query),"UPDATE `accounts` SET `GunLicense` = '%d',`GunID` = '%d',`TruckLicense` = '%d' WHERE `Name` = '%s'",
PlayerData[playerid][GunLicense],PlayerData[playerid][GunID],PlayerData[playerid][TruckLicense],pname);
mysql_query(query);