How to implement nested transactions

From: "Andrus" <eetasoft(at)online(dot)ee>
To: pgsql-general(at)postgresql(dot)org
Subject: How to implement nested transactions
Date: 2006-01-26 18:20:50
Message-ID: drb3ue$4gk$1@news.hub.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I want to implement nest transactions like

begin;
CREATE temp table t2 (foo char(20) primary key);
begin;
CREATE temp table t1 (bar char(20) primary key);
commit;
rollback;

I'm expecting that t1 and t2 tables are not created since last rollback
rolls back its nested transaction.

However, both tables are created.

Any idea hot to force parent transaction rollback to roll back committed
nested transactions ?

Andrus.

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Rich Shepard 2006-01-26 18:21:26 Re: Access Problem After Version Upgrade -- FIXED
Previous Message Seneca Cunningham 2006-01-26 18:15:46 Re: Encoding errors when upgrading from 7.4 to 8.1