From: | Vadim Mikheev <vadim(at)krs(dot)ru> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | pgsql-hackers(at)postgreSQL(dot)org |
Subject: | Re: [HACKERS] DROP TABLE inside transaction block |
Date: | 1999-09-06 01:09:47 |
Message-ID: | 37D3145B.9179323E@krs.ru |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Tom Lane wrote:
>
> Pursuant to a phone conversation I had with Bruce, I added code this
> morning to reject DROP TABLE or DROP INDEX inside a transaction block;
> that is, you can't do BEGIN; DROP TABLE foo; END anymore. The reason
> for rejecting this case is that we do the wrong thing if the transaction
> is later aborted. Following BEGIN; DROP TABLE foo; ABORT, the system
> tables will claim that foo is still valid (since the changes to them
> were never committed) but we've already unlinked foo's physical file,
> and we can't get it back. Solution: only allow DROP TABLE outside
> BEGIN, so that the user can't try to change his mind later.
What if table was created inside BEGIN/END?
Any reason to disallow DROP of local tables?
Vadim
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 1999-09-06 02:34:53 | Re: [HACKERS] relcache.c leaks refcnts |
Previous Message | Tatsuo Ishii | 1999-09-06 00:51:43 | Re: [HACKERS] md.c is feeling much better now, thank you |