MySQL errors
#4

Quote:
Originally Posted by Necro[ABK]
Посмотреть сообщение
Код:
CMD:skill(playerid,params[]){
    new pname[24];
    new query[300];
    GetPlayerName(playerid,pname,sizeof(pname));
    PlayerInfo[playerid][pRobberskill]++;
    format(query, sizeof(query), "UPDATE playerdata SET copsskill=%d WHERE user='%s'", PlayerInfo[playerid][pRobberskill], pname);
    mysql_query(query); 
    return 1;
}
That's a weird way to do it, just do it like this:

Код:
CMD:skill(playerid,params[]){
    new pname[24];
    new query[90];
    GetPlayerName(playerid,pname,sizeof(pname));
    format(query, sizeof(query), "UPDATE playerdata SET copsskill=%d WHERE user='%s'", PlayerInfo[playerid][pRobberskill]+1, pname);
    mysql_query(query); 
    return 1;
}
Reply


Messages In This Thread
MySQL errors - by MechaTech - 29.09.2012, 12:00
Re: MySQL errors - by Camacorn - 29.09.2012, 16:28
Re: MySQL errors - by Necro[ABK] - 29.09.2012, 16:32
Re: MySQL errors - by Camacorn - 29.09.2012, 16:35
Re: MySQL errors - by Necro[ABK] - 29.09.2012, 16:38

Forum Jump:


Users browsing this thread: 1 Guest(s)