Re: Transactions and insertion ordering - Mailing list pgsql-general

From Bruno Wolff III
Subject Re: Transactions and insertion ordering
Date
Msg-id 20040610134734.GA17187@wolff.to
Whole thread Raw
In response to Re: Transactions and insertion ordering  (Martijn van Oosterhout <kleptog@svana.org>)
Responses Re: Transactions and insertion ordering  (James Pharaoh <james@pharaohsystems.com>)
List pgsql-general
On Thu, Jun 10, 2004 at 20:15:53 +1000,
  Martijn van Oosterhout <kleptog@svana.org> wrote:
> nextval() should return value in the order they were called, rather
> than commit time. I hope you're not relying on the unordered results of
> a table scan remaining stable. Tables have no intrinsic "order", only
> one inposed by an external sequence.

This isn't really guarenteed with nextval. I think it will work if you
are just reserving one value at a time (which is the default).

I think the real problem is that the original poster needs to precisely
define what determines order. If the precise definition is transaction
commit order, I think that is going to be hard to do exactly right.

pgsql-general by date:

Previous
From: Karsten Hilbert
Date:
Subject: Re: Postgresql vs. aggregates
Next
From: Franco Bruno Borghesi
Date:
Subject: Re: Record order change after update