Обсуждение: Table creation in transactions

Поиск
Список
Период
Сортировка

Table creation in transactions

От
"Mihai Gheorghiu"
Дата:
I have a transaction in which a table is created at some point.
If the transaction is rolled back, does the table remain, or is it
automatically dropped?
Thank you all,
Mihai


Re: Table creation in transactions

От
John Gray
Дата:
On Tue, 2002-08-06 at 20:55, Mihai Gheorghiu wrote:
> I have a transaction in which a table is created at some point.
> If the transaction is rolled back, does the table remain, or is it
> automatically dropped?
It is dropped when the transaction is rolled back. I believe that old
(pre 7.0? ) versions of PG had problems with creating tables in a
transaction, but this hasn't been the case for a while.

Regards

John

--
John Gray
Azuli IT
www.azuli.co.uk



Re: Table creation in transactions

От
Darren Ferguson
Дата:
It will be dropped since it was part of the transaction and when you
rollback it will be removed

HTH

On Tue, 6 Aug 2002, Mihai Gheorghiu wrote:

> I have a transaction in which a table is created at some point.
> If the transaction is rolled back, does the table remain, or is it
> automatically dropped?
> Thank you all,
> Mihai
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 2: you can get off all lists at once with the unregister command
>     (send "unregister YourEmailAddressHere" to majordomo@postgresql.org)
>

--
Darren Ferguson