Il giorno dom, 18/09/2005 alle 11.41 -0400, Paul Mylchreest ha scritto:
> On 18-Sep-05, at 5:56 AM, Ksenia Marasanova wrote:
>
> > Hi,
> >
> > In psycopg1, for debugging purposes, I'd like to print every query
> > that goes to the database, after processing bound variables.
> > Is it possible?
> >
>
> How about using loggers. For example:
>
> import logging
>
> logging.debug(q % t)
With % you don't get the exact same query sent to the backend. That's
why psycopg 2 has a .query attribute.
federico
--
Federico Di Gregorio http://people.initd.org/fog
Debian GNU/Linux Developer
fog-8fiUuRrzOP0dnm+yROfE0A@xxxxxxxxxxxxxxxx
INIT.D Developer
fog-NGVKUo/i/6DYtjvyW6yDsg@xxxxxxxxxxxxxxxx
A short story: I want you. I love you. I'll miss you. -- Me
signature.asc
Description: This is a digitally signed message part
_______________________________________________
Psycopg mailing list
Psycopg-IAPFreCvJWPBWskQ1e/+sw@xxxxxxxxxxxxxxxx
http://lists.initd.org/mailman/listinfo/psycopg
|