Re: Yet another "drop table vs delete" question - Mailing list pgsql-general

From Tom Lane
Subject Re: Yet another "drop table vs delete" question
Date
Msg-id 13345.1240350171@sss.pgh.pa.us
Whole thread Raw
In response to Re: Yet another "drop table vs delete" question  (Christophe <xof@thebuild.com>)
List pgsql-general
Christophe <xof@thebuild.com> writes:
> On Apr 21, 2009, at 2:15 PM, Jeff Davis wrote:
>> In Session1, the serializable transaction sees an empty version of
>> bar, even though it had tuples in at the time Session1 got its serializable
>> snapshot.

> Indeed so, and I understand that part.  But since Session1 didn't try
> to access 'bar', it can't distinguish that sequence from:

Well, it could if the application has expectations about consistency
between the contents of 'foo' and 'bar'.  I think we have enough
interlocks to ensure that it's not possible for an explicit foreign-key
constraint to be violated that way, but the application could have
expectations that it's not formalized as an FK.  In general the point
of a serializable snapshot is to ensure that you see logically
simultaneous contents of all the tables you look at, and that will
definitely not be the case in this type of scenario.

            regards, tom lane

pgsql-general by date:

Previous
From: asceta
Date:
Subject: Re: Yet another "drop table vs delete" question
Next
From: Jeff Davis
Date:
Subject: Re: Yet another "drop table vs delete" question