From: | David Newall <postgresql(at)davidnewall(dot)com> |
---|---|
To: | pgsql-bugs(at)postgresql(dot)org |
Subject: | rollback to savepoint leads to transaction already in progress |
Date: | 2010-10-10 22:42:30 |
Message-ID: | 4CB24156.7090708@davidnewall.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs pgsql-hackers |
Hi all,
Trivial program to demonstrate problem:
main() {
ECPGdebug(1,stderr);
exec sql connect to postgres;
exec sql set autocommit to off;
exec sql start transaction;
exec sql savepoint s;
exec sql rollback to s;
exec sql commit;
return 0;
}
Output:
[28397]: ECPGdebug: set to 1
[28397]: ECPGconnect: opening database postgres on <DEFAULT> port <DEFAULT>
[28397]: ECPGsetcommit on line 4: action "off"; connection "postgres"
[28397]: ECPGtrans on line 5: action "start transaction"; connection
"postgres"
[28397]: ECPGtrans on line 6: action "savepoint s"; connection "postgres"
[28397]: ECPGtrans on line 7: action "rollback to s"; connection "postgres"
[28397]: ECPGtrans on line 8: action "commit"; connection "postgres"
[28397]: ECPGnoticeReceiver: there is already a transaction in progress
[28397]: raising sqlcode -603
Problem:
It shouldn't raise "there is already a transaction in progress" error,
particularly when doing a commit. Remove "rollback to s" and no problem.
Environment:
ecpg (PostgreSQL 8.4.5) 4.5.0
Linux thales 2.6.32-24-generic #43-Ubuntu SMP Thu Sep 16 14:58:24 UTC
2010 x86_64 GNU/Linux
Two cores
This appears to be a regression; it doesn't occur with ecpg (PostgreSQL
8.3.8) 4.4.1
Regards,
David
From | Date | Subject | |
---|---|---|---|
Next Message | Craig Ringer | 2010-10-11 01:23:56 | Re: BUG #5699: Postgres runs only under default user. |
Previous Message | Jeff Davis | 2010-10-10 18:48:54 | Re: BUG #5702: pg fails to use a conditional index even the where clause matches the condition |
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2010-10-10 22:47:01 | Re: patch: psql variables tabcomplete |
Previous Message | Craig Ringer | 2010-10-10 22:41:16 | Re: Slow count(*) again... |