Re: Yet another "drop table vs delete" question

From: Christophe <xof(at)thebuild(dot)com>
To: PostgreSQL general <pgsql-general(at)postgresql(dot)org>
Subject: Re: Yet another "drop table vs delete" question
Date: 2009-04-21 21:30:14
Message-ID: 05082BAF-226D-4FEE-9856-D22D3F956A2B@thebuild.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


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:

Session2:
BEGIN;
TRUNCATE bar;
COMMIT;

Session1:
BEGIN TRANSACTION ISOLATION LEVEL SERIALIZABLE;
SELECT * FROM foo;
SELECT * from bar;
COMMIT;

I've been trying to come up with a scenario in which a TRUNCATE
violates concurrency expectations; I'm sure one exists, but my brain
isn't wrapping around it.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2009-04-21 21:34:55 Re: Yet another "drop table vs delete" question
Previous Message Jeff Davis 2009-04-21 21:15:10 Re: Yet another "drop table vs delete" question