log_statement and Parse/Bind

From: Oliver Jowett <oliver(at)opencloud(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Subject: log_statement and Parse/Bind
Date: 2004-05-25 02:28:57
Message-ID: 40B2AF69.5010403@opencloud.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

I notice that when using the extended query protocol, statement logging
appears to happen only when a Parse message is received. This is less
than ideal:

- statements can be logged that are not actually executed (i.e. a
Parse/Bind with no corresponding Execute).
- if statements are re-executed without an intervening Parse (i.e.
Parse/Bind/Execute/Bind/Execute/...), only the first execution is logged.

There's also a lesser problem with using parameterized queries: the
actual parameter values used in a Bind are not visible. This is the same
as the PREPARE/EXECUTE case, except that it's more likely to be done
transparently by the client's interface library (so we can't just tell
the application developer "don't do that, then!")

Are there any plans to change this? Should I look at making a change
along the lines of logging the statement on the first Execute of a
portal, instead of on Parse?

-O

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2004-05-25 02:29:13 Re: New horology failure
Previous Message Bruce Momjian 2004-05-25 02:21:56 Ingres to be released as open source