> >
> > Tom Lane wrote:
> >
> >> Andrew Dunstan <[EMAIL PROTECTED]> writes:
> >>
> >>> I did think about using a cluster-wide sequence, if we can make such
> >>> a thing (might also be useful for system generated UIDs too).
> >>
> >> Not a good idea IMHO.  If you do that, then there will be no such thing
> >> as a purely read-only transaction, because *every* transaction will
> >> include a nextval() call.  That means even read-only transactions cannot
> >> commit till the disk spins.
> >>

A sequence could be used if it was created with a sufficiently large CACHE
value, so a read only transaction would only have to hit the disk if it
happened to be the one to hit an exhausted cache.

Kris Jurka


---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

Reply via email to