Unexpected EXPLAIN's with php & mysql
Date: 03/14/07
(PHP Community) Keywords: php, mysql, sql
solved: Turns out there was a ini_set, mysql.trace buried in the job configuration file so that kicked off the pre-emptive explains on everything.
While debugging another issue, I had the general/slow query logs enabled and tailed. What caught me off guard and I assume this is part of the php mysql library, is that every single select query was being preceeded with EXPLAIN SELECT . I've looked through the mysql_ library docs and there is no mention of this. Direct mysql queries from the console don't have these preceeding EXPLAINS so it's got to be something unexpected inside the php code library.
Source: http://community.livejournal.com/php/551962.html