Query Mysql
#2

pawn Код:
format(str,sizeof(str),"UPDATE `players` SET `Money=%d,CurrentHealth=%d,Level=%d,HouseKey=%d,BizKey=%d,Cigarettes=%d,Rope=%d,HasGlasses=%d,Skin=%d,CurrentX=%d,CurrentY=%d,",
PlayerAccount[playerid][Money],PlayerAccount[playerid][Health],PlayerAccount[playerid][Level],PlayerAccount[playerid][HouseKey],PlayerAccount[playerid][BizKey],PlayerAccount[playerid][Cigarettes],PlayerAccount[playerid][Rope],PlayerAccount[playerid][HasGlasses],PlayerAccount[playerid][Skin],PlayerAccount[playerid][pPos][0],PlayerAccount[playerid][pPos][1]);

format(str,sizeof(str),"%sCurrentZ=%d,CurrentInt=%d,CurrentVW=%d,ID=%d,HasMask=%d,HasHelmet=%d,PhoneCredit=%d,CurrentArmour=%d,Sex=%d,Drug=%d,Materials=%d,FightStyle=%d,",str,
PlayerAccount[playerid][pPos][2],PlayerAccount[playerid][CurrentInt],PlayerAccount[playerid][CurrentVW],PlayerAccount[playerid][ID],PlayerAccount[playerid][HasMask],PlayerAccount[playerid][HasHelmet],PlayerAccount[playerid][PhoneCredit],AccountData[playerid][pArmour],PlayerAccount[playerid][psex],PlayerAccount[playerid][Drug],PlayerAccount[playerid][Materials],PlayerAccount[playerid][FightStyle]);

format(str,sizeof(str),"%sWalk=%d,Premium=%d,WalkieTalkie=%d,Phone=%d,Clan=%d,ClanLeader=%d,Faction=%d,CurrentDuty=%d,Rank=%d,CurrentDutySkin=%d,Subfaction=%d,",str,
PlayerAccount[playerid][Walk],PlayerAccount[playerid][Premium],PlayerAccount[playerid][WalkieTalkie],PlayerAccount[playerid][Phone],PlayerAccount[playerid][Clan],PlayerAccount[playerid][ClanLeader],PlayerAccount[playerid][Faction],PlayerAccount[playerid][CurrentDuty],PlayerAccount[playerid][Rank],PlayerAccount[playerid][CurrentDutySkin],PlayerAccount[playerid][Subfaction]);

format(str,sizeof(str),"%sBank=%d,Prestito=%d,Pay=%d,Jailed=%d,JailTime=%d,JailCell=%d,Exp=%d,Years=%d,Pills=%d,TutorialDone=%d,Admin=%d,Banned=%d,GPS=%d,",str,
PlayerAccount[playerid][Bank],PlayerAccount[playerid][Prestito],PlayerAccount[playerid][Pay],PlayerAccount[playerid][Jailed],PlayerAccount[playerid][JailCell],PlayerAccount[playerid][JailTime],PlayerAccount[playerid][Exp],PlayerAccount[playerid][Years],PlayerAccount[playerid][Pills],PlayerAccount[playerid][TutorialDone],PlayerAccount[playerid][AdminLevel],PlayerAccount[playerid][Banned],PlayerAccount[playerid][GPS]);

format(str,sizeof(str),"%sClock=%d,Poste=%d,Worker=%d,Capelli=%d,Helper=%d,MotorBikeLic=%d,CarLic=%d,TruckLic=%d,BusLic=%d,BoatLic=%d,FlyLic=%d,Spawned=%d,",str,
PlayerAccount[playerid][Clock],PlayerAccount[playerid][Poste],PlayerAccount[playerid][Worker],PlayerAccount[playerid][Capelli],PlayerAccount[playerid][Helper],PlayerAccount[playerid][License][0],PlayerAccount[playerid][License][1],PlayerAccount[playerid][License][2],PlayerAccount[playerid][License][3],PlayerAccount[playerid][License][4],PlayerAccount[playerid][License][5],PlayerAccount[playerid][Spawned]);

format(str,sizeof(str),"%sSpawn=%d,Activity=%d,ActivityLeader=%d,exgm=%d,WepLic=%d,District=%d,SubDistrict=%d,WeaponString", ='%s',BanDays", ='%s',PremDays='%s'",str,
PlayerAccount[playerid][Spawn],PlayerAccount[playerid][Activity],PlayerAccount[playerid][ActivityLeader],PlayerAccount[playerid][exgm],PlayerAccount[playerid][License][6],PlayerAccount[playerid][District],PlayerAccount[playerid][SubDistrict],PlayerAccount[playerid][WepString],PlayerAccount[playerid][BanDays],PlayerAccount[playerid][PremDays]);
format(str,sizeof(str),"%s WHERE `name`='%s';",str,NAME);
Viva la REGEX.
Reply


Messages In This Thread
Query Mysql - by fabriziobondi - 21.11.2011, 11:51
Re: Query Mysql - by FarSe. - 21.11.2011, 12:07
Re: Query Mysql - by fabriziobondi - 21.11.2011, 12:10
Re: Query Mysql - by iJumbo - 21.11.2011, 12:24
Re: Query Mysql - by fabriziobondi - 21.11.2011, 12:46
Re: Query Mysql - by FarSe. - 21.11.2011, 12:47
Re: Query Mysql - by fabriziobondi - 21.11.2011, 12:55
Re: Query Mysql - by AndreT - 21.11.2011, 13:02
Re: Query Mysql - by fabriziobondi - 21.11.2011, 13:13
Re: Query Mysql - by fabriziobondi - 21.11.2011, 13:44

Forum Jump:


Users browsing this thread: 2 Guest(s)