Don't ever repair or optimize a database if you don't have to. Repairs should only be run if the table is actually crashed. Optimize if and only if you've removed large groups of data from an myisam table.
If you run that query yourself, do you get any errors?
Without an error message hard to tell. php might have timed out and killed the query/connection. or MySQL timed out and killed the query, which made php exit and give you an error. But its weird you're not getting an error message.
|