Re: [GENERAL] using DROP in a transaction

2008-02-17 Thread Chris
Willy-Bas Loos wrote: ah, of course. the exclusive lock was preventing tty1 to read "test", and when the lock was gone, so was the table. I get it. Thanks a lot. But, what about the "ERROR: tuple concurrently updated" ? (in TTY3) Same thing - tty1 was locking that entry and when it was relea

Re: [GENERAL] using DROP in a transaction

2008-02-15 Thread Willy-Bas Loos
ah, of course. the exclusive lock was preventing tty1 to read "test", and when the lock was gone, so was the table. I get it. Thanks a lot. But, what about the "ERROR: tuple concurrently updated" ? (in TTY3) What should have happened, i guess, is "ERROR: table "test" does not exist, upon " drop t

Re: [GENERAL] using DROP in a transaction

2008-02-14 Thread Chris
==in TTY1== --11. expect result at last, value 2 only. (concurrent transaction 2 (in TTY3) completes after this, and will delete values 2 and 4 (added after select was issued) upon commit) --11. true result: ERROR: relation deleted while still in use The table 'test'

Re: [GENERAL] using DROP in a transaction

2008-02-14 Thread Willy-Bas Loos
this is really bugging me. am i doing something stupid? On Fri, Feb 8, 2008 at 2:18 PM, Willy-Bas Loos <[EMAIL PROTECTED]> wrote: > ok, that explains. > so i go on with my test, which still doesn't turn out as i expected > (PostgreSQL 8.1.10). > why?? > > ==in TTY1== (start.sql) > create table t

Re: [GENERAL] using DROP in a transaction

2008-02-08 Thread Willy-Bas Loos
ok, that explains. so i go on with my test, which still doesn't turn out as i expected (PostgreSQL 8.1.10). why?? ==in TTY1== (start.sql) create table test (id int4 primary key); --expect sucess insert into test (id) values (1); --expect success ==in TTY2== (tr1a.sql) begin; --expect success drop

Re: [GENERAL] using DROP in a transaction

2008-02-07 Thread Tom Lane
"Willy-Bas Loos" <[EMAIL PROTECTED]> writes: > then in TTY2, run > begin; > drop table test; > create table test (id int4 primary key); > insert into test (id) values (2); > then, in TTY1: > select * from test; > Actually, i thought of a longer test, but it stops here - there is no > re

Re: [GENERAL] using DROP in a transaction

2008-02-07 Thread Willy-Bas Loos
er.. never mind the BDE part, it has nothing to do with this. On Feb 8, 2008 12:53 AM, Willy-Bas Loos <[EMAIL PROTECTED]> wrote: > Hi, > > We have a large set of simple queries, that can run in both PostgreSQL and > BDE (Corel Paradox backend). > We want to be able to re-create some half-product

[GENERAL] using DROP in a transaction

2008-02-07 Thread Willy-Bas Loos
Hi, We have a large set of simple queries, that can run in both PostgreSQL and BDE (Corel Paradox backend). We want to be able to re-create some half-product tables (cache, sortof), while they are (possibly) being accessed by other users. Otherwise there would be a severe performance penalty. We w