Re: same sequence as primary key in more than one table

From: joel garry <>
Date: Mon, 15 Jun 2009 09:37:18 -0700 (PDT)
Message-ID: <>

On Jun 15, 2:26 am, student4life <> wrote:
> Hello,
>  For example, I have 'sellers' and 'buyers' both need to authenticate
> from a database table 'users' with sequence as primary key which is
> also as primary key in tables 'sellers' and 'buyers' (both have one-to-
> one relationship with 'users') but I am not sure whether it's good
> practice to have sequence number jumping alternatively between tables.
> Could someone inform me what the best practice/design is under the
> scenario? TIA

You might have enqueue scaling issues if you share sequences between tables. How bad is app and version dependent, newer versions may not be so bad. You can even have problems with multiple instances on a sequence for logging in if the usage is high enough. See,1

Of course, if you don't use RAC, you may not care, but it does tend to highlight where best practices are not followed. How volatile are sellers, buyers and users, anyways?


-- is bogus.
AAA Dimaond Award
Received on Mon Jun 15 2009 - 11:37:18 CDT

Original text of this message