Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: share sequences between tables or one to one

Re: share sequences between tables or one to one

From: Jan-Peter Meyer <jan-peter.meyer_at_mch.sbs.de>
Date: 1997/12/25
Message-ID: <34A23FDC.19CC95FB@mch.sbs.de>#1/1

I use one sequence number for an entire application to generate unique keys for all tables and consider it an integrity feature. It makes it impossible to produce incorrect query answers, when joining tables incorrectly.

Lothar Armbruester wrote:
>
> Todd Storch schrieb am 10-Dez-97 15:59:46
> zum Thema "share sequences between tables or one to one":
> >I inherited a schema that uses sequences that are shared between tables.
> >When a sequence needs to be recreated I have to check the MAX value for
> >several tables then set the start value of the sequence. This can be time
> >consuming when many tables use the same sequence. Is there any down side
> >to creating a sequence for each table in the schema. i.e. TABLENAME_SEQ ?
>
> I think, when You have a sequence for every table forces You to eventually
> recreate many sequences which is also time consuming when You have to get
> the maximum numbers. You can do this one after another so you have several
> small runtimes instead of one big.
> Apart from this I don't think there is no drawback having a sequence for
> every table. Of course you have to update all references to your only
> sequences when introducing the new sequence names.
>
> >Thanks
>
> Hope that helps,
> Lothar
>
> --
> Lothar Armbrüster | lothar.armbruester_at_rheingau.netsurf.de
> Schulstr. 12 | lothar.armbruester_at_t-online.de
> D-65375 Oestrich-Winkel |
 

-- 
---------------------------------------------------------------------
Jan-Peter Meyer                            jan-peter.meyer_at_mch.sbs.de
Siemens Business Services                  IS E 1
---------------------------------------------------------------------
--
Received on Thu Dec 25 1997 - 00:00:00 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US