The following bug has been logged online:
Bug reference: 1220
Logged by: adam sah
Email address: asah@midgard.net
PostgreSQL version: 7.4.3
Operating system: linux (suse 9.1 professional)
Description: "alter table rename to" inside a transaction violates
ACID ordering
Details:
to repro, open two psql windows and execute cmds in this order:
in window 1, "create table test (foo integer);"
in window 2, "select count(*) from foo;"
in window 1, "begin transaction;"
in window 2, "select count(*) from foo;"
in window 1, "alter table foo rename to bar;"
in window 2, "select count(*) from foo;"
==> this blocks, like it should
in window 1, "commit;"
==> yikes! in window 2, it should have errored.
instead it succeeded with 0 records (I'm guessing
because the catalog lookup had already occurred?)
anyway, if you try the same thing, but with "drop
table" instead of rename you do get an error in the
query window.
btw, you guys rock! 8.0 looks awesome.
hope this helps,
adam
(former UC Berkeley grad student in stonebraker's
database group)