Nested Transactions

From: cbroussard(at)liquiddatainc(dot)com (Chris)
To: pgsql-general(at)postgresql(dot)org
Subject: Nested Transactions
Date: 2002-03-08 07:12:33
Message-ID: 89b6b185.0203072312.a830c8d@posting.google.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

i'm trying to accomplish the following task:

begin transaction;
begin work;
create table xyz(
id int
);
commit work;
select * from xyz;
rollback transaction;
select * from xyz; // should say database object doesn't exist

however i'm failing to be able to do this?? is there a specific reason?

I know in MSSQL you can say:

begin transaction
begin transaction test
create table xyz(
id [int]
);
select * from xyz
commit transaction test
rollback transaction
select * from xyz // database object doesn't exist

Is there an equivalent?

TIA

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Martijn van Oosterhout 2002-03-08 07:12:38 Re: April 1
Previous Message Carlo Florendo 2002-03-08 06:57:10 URGENT! VIRUS ALERT