mysql count
#3

its not working. This is what im using.



Код:
new name[MAX_PLAYER_NAME+1], string[24+MAX_PLAYER_NAME+1];
GetPlayerName(playerid, name, sizeof(name));
new query[300];
mysql_format(MySQLCon, query, sizeof(query), "SELECT COUNT(*) as count FROM objects WHERE Owner = '%s';",name);
mysql_query(MySQLCon, query);
new rows, fields, temp[120];
cache_get_data(rows, fields);
new string2[32];
format(string2, sizeof(string2), "You have %d Furniture Pieces", rows);
SendClientMessage(playerid, COLOR_YELLOW, string2);
when i have more than one object it is stuck at telling me 1
Reply


Messages In This Thread
mysql count - by jeffery30162 - 18.01.2015, 23:42
Re: mysql count - by CoaPsyFactor - 18.01.2015, 23:47
Re: mysql count - by jeffery30162 - 19.01.2015, 00:04
Re: mysql count - by jeffery30162 - 19.01.2015, 00:49
Re: mysql count - by PaulDinam - 19.01.2015, 01:57
Re: mysql count - by CoaPsyFactor - 19.01.2015, 02:10
Re: mysql count - by CoaPsyFactor - 19.01.2015, 02:12
Re: mysql count - by PowerPC603 - 19.01.2015, 06:42
Re: mysql count - by jeffery30162 - 19.01.2015, 19:16
Re: mysql count - by jeffery30162 - 19.01.2015, 19:23

Forum Jump:


Users browsing this thread: 1 Guest(s)