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: null as part of key?

Re: null as part of key?

From: Niall Litchfield <n-litchfield_at_audit-commission.gov.uk>
Date: Tue, 23 Oct 2001 17:38:50 +0100
Message-ID: <3bd59d16$0$238$ed9e5944@reading.news.pipex.net>


"ed zappulla" <zappullae_at_rcn.com> wrote in message news:9r42mp$jv0$1_at_bob.news.rcn.net...
> many countries do not have postal codes. Ireland for one.
>
> country, state, city is the proper key with a null state being valid.
>
>

Didn't know that which given my name is somewhat embarrassing <vbg>.

if you have two records with the same country and city and a null state then logically they could be the same place and hence violate the uniqueness requirement for a primary key, or they might not be the same place and so not violate the uniqueness requirement. who can tell? Certainly not oracle which is why a primary key must be not null and unique.

--
Niall Litchfield
Oracle DBA
Audit Commission UK
Received on Tue Oct 23 2001 - 11:38:50 CDT

Original text of this message

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