Posts: 6,236
Threads: 310
Joined: Jan 2011
Reputation:
0
When using 'SELECT * FROM ...' and then using mysql_fetch_field_row, my server crashes. When using 'SELECT Level FROM ...' however then getting the 'Level' field with mysql_fetch_field_row, it works fine. Does * mean nothing or all? I'm fairly certain it selects everything. Why does it crash? Using BlueG or Gtstylezzzzzzzzzzzzzzz or whatever's plugin.
Posts: 10,066
Threads: 38
Joined: Sep 2007
Reputation:
0
Yes, the star selects everything. But as the name implies, mysql_fetch_field_row is to be used to fetch the data from a single field. If you're looking to get more data from different fields, you're better off using mysql_fetch_row and splitting the result afterwards with sscanf.
Posts: 6,236
Threads: 310
Joined: Jan 2011
Reputation:
0
But what I'm saying is, if I need 100 fields, if I do
SELECT field1, field2, field3 etc.
it's going to need a massive string. Can't I just do
SELECT * FROM x ...
Then get the fields with the function?