Home > Archive > Slony1 PostgreSQL Replication > September 2005 > Re: silly question time









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: silly question time
Christopher Browne

2005-09-14, 8:25 pm

Robert Bernier wrote:

>What are the issues, of adding tables to a set using the "set add table" but
>NOT "set add sequence" for sequences that the tables use such as for example
>serial data-types i.e. the sequences are already created and initialized to
>the correct value for each and every node?
>
>

If you don't add the sequence in, then if you subsequently switch the
origin to a new node, it won't know about the sequence updates, and will
presumably imagine it should start numbering things somewhere earlier.

You'll start seeing primary key violations in cases where the sequence
is used to populate a PK field.

The "danger" case is where a sequence is used in a more subtle fashion
such as to refer to some sort of common across-multiple-tables
transaction ID. We once ran into a case where a sequence of that sort
was handled wrongly and it caused a veritable plague of billing problems
as unrelated transactions started linking to one another :-(.
Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com