RE: [PEAR] MDB debug
| From: | Lukas Smith | Date: | Mon, 05 May 2003 10:26:04 +0000 |
| Subject: | RE: [PEAR] MDB debug | ||
| References: | 1 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-5231@lists.php.net to get a copy of this message | ||
> From: Jeroen Houben [mailto:jeroen@terena.nl]
> Sent: Monday, May 05, 2003 12:16 PM
> Lukas Smith wrote:
>
> >>From: Jeroen Houben [mailto:jeroen@terena.nl]
> >>Sent: Monday, May 05, 2003 11:17 AM
> >>To: pear-general@lists.php.net
> >>Subject: [PEAR] MDB debug
> >>
> >>Hi,
> >>
> >>Is there any way to make MDB show the queries it's sending to the
> >>database? I'm having some trouble debugging executeMultiple calls.
> >>
> >>
> >
> >Yes there is.
> >Have a look at MDB_test.php in the tests directory. Towards the
bottom I
> >show a sample use of the debugging facilities of MDB.
> >
> >You can even extend them by defining your own customer debug handler.
> >
> >
> great! thanks.
>
> I'm just vardumping it which seems to work, however I get this output
>
> (1 Query: $query
> 1 Query: $query
> 1 Query: $query
> 1 PrepareQuery: UPDATE docsections SET section_id=35 WHERE doc_id=?
> 1 Query: $query)
>
> Why is it showing $query instead of the actual query?
Because you spotted a bug in the pgsql driver. Which I just fixed.
Regards,
Lukas