| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> comp.databases.theory -> Re: NextNumbers Tables
"Alan Gutierrez" <ajglist_at_izzy.net> wrote in message
news:1XO1a.20790$tQ1.1398507_at_news2.east.cox.net...
> I don't know if you are listening but, don't use a next number. Find a
> a natural primary key.
Why? My uni teacher used to say always use a surrogate key. It stops you from duplicating keys later. What advantages does it have over using IDs?
>If you absolutely cannot find one, use the
> sequence facilities provided by your db. Now you are going to have to
> find some other way to check for duplicate entries in your database. If
> there is no sequence facility provided by your db, get a different db.
I wish! DB2 as/400 dont have ID.
Chesrs
Stu
> If you cannot get a different db then do this:
> --
> Alan Gutierrez - ajglist_at_izzy.net
Received on Mon Feb 10 2003 - 10:05:27 CST
![]() |
![]() |