Re: PostgreSQL transaction locking problem

From: Stephan Szabo <sszabo(at)megazone23(dot)bigpanda(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: <jeff(at)dgjc(dot)org>, <pgsql-general(at)postgresql(dot)org>
Subject: Re: PostgreSQL transaction locking problem
Date: 2002-02-02 19:27:37
Message-ID: 20020202110937.S42811-100000@megazone23.bigpanda.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


On Sat, 2 Feb 2002, Tom Lane wrote:

> "Jeff Martin" <jeff(at)dgjc(dot)org> writes:
> > LOCK TABLE Test IN EXCLUSIVE MODE;
>
> > /* This function should be able to operate concurrently BUT CANNOT */
>
> How you figure that? EXCLUSIVE lock is clearly documented to be
> self-conflicting; so only one process can hold it at a time. See
> http://www.ca.postgresql.org/users-lounge/docs/7.1/postgres/locking-tables.html
>
> If concurrency is important I'd suggest generating your ID values using
> a sequence generator, rather than trying to build your own
> implementation.

I actually thought that he's complaining about the fact that it gives him
the same id twice if he runs it in two transactions rather than the delay
until the first commits.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2002-02-02 20:40:53 Re: PostgreSQL transaction locking problem
Previous Message Mitch Vincent 2002-02-02 19:23:03 Re: ERROR: OUTER JOIN is not yet supported