Re: some log statements ignored

From: brian <brian(at)zijn-digital(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: some log statements ignored
Date: 2006-10-13 16:47:01
Message-ID: 452FC305.3080303@zijn-digital.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Bruce Momjian wrote:
> brian wrote:
>
>>I changed my postgresql.conf to have:
>>
>>log_statement = mod
>>
>>It appears to be working, though not logging *all* INSERTs. For
>>instance, I have a PHP class that inserts into two tables in a
>>transaction. The log shows the first, but not the second. Has anyone
>>seen this behaviour?
>>
>>
>>test=# show log_statement;
>> log_statement
>>---------------
>> mod
>>(1 row)
>
>
> I have no idea why that would happen. If you do 'all' do you see all of
> them?
>

Sorry--i hadn't had time to run a test. Setting it to 'all' works fine,
and i think i see the problem: the second INSERT is in a prepared
statement, so it's not being logged.

PREPARE mdb2_statement_pgsql00fb05c2c509aa2608b68bf2b87693a2 AS INSERT
INTO ...

(this is using the PEAR MDB2 package)

So, log_statement= 'mod' won't log a "PREPARE ... AS INSERT", i guess.

b

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Martijn van Oosterhout 2006-10-13 16:58:27 Re: UTF-8
Previous Message Bob Pawley 2006-10-13 16:42:02 Query