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: Any way to do "unique or null"?

Re: Any way to do "unique or null"?

From: <nasof_at_hotmail.com>
Date: Mon, 14 Sep 1998 18:13:37 GMT
Message-ID: <6tjmcg$cl6$1@nnrp1.dejanews.com>


Oracle allows you to have multiple nulls in a SINGLE unique column "constraint". But composite unique keys (which create a unique indexs) can only have one occurance of all nulls. Make sense? not really...

-Frank

In article <6tj9j2$orr_at_enews4.newsguy.com>,   "Leo D'Souza" <ldsouza_at_perigee.net> wrote:
> Since Oracle does not store null's in an index....creating a unique
> index should do it. I've not tested this out but it should work.
>
> - Leo
>
> Reid Lai wrote in message <35F8BFD4.9EBF1D95_at_hk.super.net>...
> >You should use BEFORE INSERT trigger to do so instead of constraint.
> >
> >Roy Smith wrote:
> >
> >> I've got a column which I want to allow to be null, but if there is a
> >> value in it, I want to ensure that value is unique amongst the non-null
> >> entries. Can a constraint be used to do this?
> >>
> >> --
> >> Roy Smith <roy_at_popmail.med.nyu.edu>
> >> New York University School of Medicine
> >
> >
> >
>
>

-----== Posted via Deja News, The Leader in Internet Discussion ==----- http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum Received on Mon Sep 14 1998 - 13:13:37 CDT

Original text of this message

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