Michael Glaesemann <[EMAIL PROTECTED]> writes:
> On May 31, 2007, at 11:46 , [EMAIL PROTECTED] wrote:
>> However, I wondered, if I were in an environment where there were many
>> concurrent inserts, would it be possible that I didn't get the serial
>> number of the insert that *I* just did?

> No.

Uh, yes, because he was using "SELECT last_value FROM seq" which is
indeed subject to race conditions.  currval() would be far safer.

                        regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

               http://www.postgresql.org/docs/faq

Reply via email to