Re: A bad behavior under autocommit off mode - Mailing list pgsql-hackers

From Hiroshi Inoue
Subject Re: A bad behavior under autocommit off mode
Date
Msg-id 3E556EF4.244FB87F@tpf.co.jp
Whole thread Raw
In response to Re: A bad behavior under autocommit off mode  ("Hiroshi Inoue" <inoue@tpf.co.jp>)
Responses Re: A bad behavior under autocommit off mode  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Tom Lane wrote:
> 
> "Hiroshi Inoue" <inoue@tpf.co.jp> writes:
> > The simplest way seems to accept COMMIT any time under autocommit
> > off mode.
> 
> That's just hiding the most visible symptom.  The real problem here is
> that the SELECT is already committed, when it shouldn't be.

The warning means that the transaction is not yet begun
before the chained query is issued. The check seems originally
for COMMIT without BEGIN under autocommit on mode. It also
cancels a transaction for the query '..;..;commit;..' under
autocommit on mode. It's also bad because it only reports a
warning. Anyway should 'set autocommit to off;commit' cause
a warning or an error in the first place ?

regards,
Hiroshi Inouehttp://www.geocities.jp/inocchichichi/psqlodbc/


pgsql-hackers by date:

Previous
From: Josh Berkus
Date:
Subject: Re: request for sql3 compliance for the update command
Next
From: Tom Lane
Date:
Subject: Re: A bad behavior under autocommit off mode