Quote:
Originally Posted by Pedro_Miranda
mysql_format + mysql_function_query
|
Quote:
Originally Posted by Hawky133
Hello.
You need to format your query BEFORE you use it in mysql_function_query. Right now, your query is doing this:
Username=%s
Money=%d
Score=%d
IP=%s
TOS=%s
You need to format your string before this point like this:
pawn Код:
new query[256]; mysql_format(connectionHandle,query,"INSERT INTO memmbers (Username, Money, Score, IP, TOS) VALUES ('%s','%d','%d','%s','%s')",pname,GetPlayerMoney(playerid), GetPlayerScore(playerid), IP,TStr); //Where connectionHandleis the ID of your connection to the mysql database
And then you can run the query:
pawn Код:
mysql_function_query(connectionHandle,query,false,"OnQueryFinish","siiss",pname,GetPlayerMoney(playerid), GetPlayerScore(playerid), IP,TStr);
|
ok i know what iv done wrong
i didnt event know that function before it was a simple
format
anyways tnx