Re: [GENERAL] Auto increment/sequence on multiple columns?

2004-09-15 Thread Thomas F . O'Connell
You'll probably need a sequence per thread. A sequence is not necessarily tied to a column. -tfo On Sep 12, 2004, at 11:16 AM, Nick wrote: This is actually a table that holds message threads for message boards. Column A is really 'message_board_id' and column B is 'thread_id'. I would like every

Re: [GENERAL] Auto increment/sequence on multiple columns?

2004-09-15 Thread Bruno Wolff III
On Sun, Sep 12, 2004 at 09:16:37 -0700, Nick <[EMAIL PROTECTED]> wrote: > This is actually a table that holds message threads for message > boards. Column A is really 'message_board_id' and column B is > 'thread_id'. I would like every new thread for a message board to have > a 'thread_id' of 1 a

Re: [GENERAL] Auto increment/sequence on multiple columns?

2004-09-11 Thread Thomas F . O'Connell
How does this imply one sequence? Is it guaranteed that for each value of a, the values of b will be equivalent to all (and only) values of a? There's plenty of flexibility within postgres for ways to use sequences. Regardless, I think you need to have (and present) a better idea of what you're

[GENERAL] Auto increment/sequence on multiple columns?

2004-09-10 Thread Nick
Is it possible to have a sequence across two columns. For example table1 +---+---+ | a | b | +---+---+ | 1 | 1 | | 1 | 2 | | 1 | 3 | | 2 | 1 | | 2 | 2 | | 2 | 3 | | 3 | 1 | | 3 | 2 | | 3 | 3 | +---+---+ Would I have to create a new sequence for every unique 'a' column? That seems pretty tedious.