Skip site navigation (1) Skip section navigation (2)

Re: ERROR: tuple concurrently updated

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Zubkovsky, Sergey" <Sergey(dot)Zubkovsky(at)transas(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: ERROR: tuple concurrently updated
Date: 2007-03-28 18:02:19
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-bugs
"Zubkovsky, Sergey" <Sergey(dot)Zubkovsky(at)transas(dot)com> writes:
> create table t1 ( id int );
> create temp view v1 as select * from t1;
> C1: begin; drop view v1;
> C2: drop table t1;
> C1: commit;

This seems a variant of the problem noted by Michael Fuhr some time ago:

but I think it shows that the solution I proposed in that thread is
still not adequate.  To deal with the above, it seems like dropping v1
would have to acquire a shared lock on t1, thereby preventing the drop
of t1 from starting until after v1 is safely gone.  Or maybe have the
drop of t1 recheck to see if v1 is still there after it has acquired
lock on v1, but I'm afraid that might be too late to prevent an update
conflict on the pg_depend row that both transactions want to delete.

			regards, tom lane

In response to


pgsql-bugs by date

Next:From: zakyDate: 2007-03-29 08:22:29
Subject: undefined symbol: krb5_cc_get_principal
Previous:From: Zubkovsky, SergeyDate: 2007-03-28 10:03:08
Subject: ERROR: tuple concurrently updated

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group