If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

But calling any of the other fetch functions (e.g. fetch_assoc) doesn't work, whether calling them procedurally or using the class interface. (NB $result->fetch_array(MYSQLI_NUM) is OK too.

So if I replace the fetch in the above code with the following
while ($row2 = $result->fetch_assoc())
echo "hello world<br>";

Then I end up with a Page Load Error - "Network Timeout - The operation timed out when attempting to contact www.localhost.com"

I can get by with the fetch_row, but would prefer to use fetch_assoc.
$finfo = $result->fetch_fields() works completely as expected, so I think the DB is working as I'd expect it to. Fields returned by it are as follows:
Table: real_club
Name: name
Flags: 4097
Type: 253

Table: real_club
Name: shortname
Flags: 4097
Type: 253

I am using php 5.2.8, MySql 5.1.31.

Any ideas would be appreciated. It seems like a very strange way for the call to fail.

I don't know of any reason why fetch_row() should work but not fetch_assoc(). All I can think of without more info to go by is that the client mysql programs (e.g. the DLLs if a Windows installation) are somehow corrupt or missing. You might want to try to find the smallest, simplest piece of code that will replicate the error and post it here to see if we can detect anything "odd" about it -- or doing so might help you find the problem yourself. (Be sure to turn on all error_reporting.)

"Please give us a simple answer, so that we don't have to think, because if we think, we might find answers that don't fit the way we want the world to be."
~ Terry Pratchett in Nation

more info...

Thanks for the suggestion.

This file replicates the problem. Set $fetchRow = true and it works exactly as expected. Set $fetchRow to false and the Network Timeout error appears.
NB To run the program I type localhost/sqli_issue.php into the browser. When I get the problem the URL becomes 'http://www.localhost.com/sqli_bug.php' after the timeout (about 30s).