Re: Select max(id) causes AccessExclusiveLock? - Mailing list pgsql-general

From Stephen Frost
Subject Re: Select max(id) causes AccessExclusiveLock?
Date
Msg-id 20140428173029.GL2556@tamriel.snowman.net
Whole thread Raw
In response to Re: Select max(id) causes AccessExclusiveLock?  (Edson Richter <edsonrichter@hotmail.com>)
List pgsql-general
Edson,

* Edson Richter (edsonrichter@hotmail.com) wrote:
> The programmer added a
>
> LOCK TABLE MyTableName
>
> just before issuing the select max(id) from MyTableName.
>
> I do suspect this is the case, right?

Yup, that'll do it.

http://www.postgresql.org/docs/9.3/static/sql-lock.html

    Thanks,

        Stephen

Attachment

pgsql-general by date:

Previous
From: Edson Richter
Date:
Subject: Re: Select max(id) causes AccessExclusiveLock?
Next
From: David Ekren
Date:
Subject: xml question