Posts: 2,502
Threads: 26
Joined: Apr 2007
Reputation:
0
Either way, why do you select all of the information in that row if you're not going to use it? Just select the column that you're trying to get.
Posts: 6,129
Threads: 36
Joined: Jan 2009
Quote:
Originally Posted by JaTochNietDan
Well in his code he was originally selecting everything, but only using a single value:
pawn Код:
UserStats[playerid][Admin] = strval(field[2]);
That's all that was in the snippet anyway, so if he was just going to use that value, why select everything? Just select admin or whatever you called that column.
pawn Код:
"SELECT ColumName FROM `table` WHERE Name = 'something'"
|
You need to wrap 'grave accents' (`) around each column/field if you use one in your query, otherwise the query won't work.
Posts: 6,129
Threads: 36
Joined: Jan 2009
I've helped quite a few people fix their queries by wrapping columns/field names appropriately, so that's odd.