Re: I'm puzzled by a foreign key constraint problem

From: Craig Ringer <craig(at)postnewspapers(dot)com(dot)au>
To: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: I'm puzzled by a foreign key constraint problem
Date: 2008-11-05 03:14:10
Message-ID: 49110F82.7050402@postnewspapers.com.au
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Jonathan Guthrie wrote:

> The thing is, the C++ code does this
>
> BEGIN transaction 1
> INSERT project
> COMMIT
>
> BEGIN transaction 2
> SET permissions
> COMMIT
>
> or, at least, it's supposed to.

OK, and we know that if it is doing what it is supposed to, transaction
2 /must/ see the changes made by transaction 1. Either it's not doing
what it's supposed to, or you've hit a mind bogglingly huge bug in
PostgreSQL that's never been noticed before. I'm inclined to suspect the
former.

Tom Lane pointed out where to go from here re the server logging. It'll
be interesting to see what turns up once you've got new logs that show
the backend pid and the involved xid.

Sorry about hammering on the point re transaction interleaving and so
on. You do see people here who've misunderstood how MVCC visibility
works, and I wasn't sure from your mail that your transactions didn't
overlap.

--
Craig Ringer

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message praveen 2008-11-05 07:01:21 Re: Installation Error of postgresql-8.1.5 with perl.
Previous Message Tom Allison 2008-11-05 00:32:08 Re: postgresql and Mac OS X