RE: unique index implications
Posted in 2000
Topics: General Discussion
> Does a unique index mean that no nulls are allowed in the columns for that index? Nope. A single null is allowed. The unique index will only allow one undefined record. > How can this be so if null is by definition undefined and has no equivalence? How can something be by definition undefined ?? Surely you mean that a null is by undefinition undefined. Rekaish -----Original Message----- From: Red Valsen [mailto:red_valsen@yahoo.com] Sent: 09 February 2000 13:18 To: informix-list@iiug.org Subject: unique index implications Does a unique index mean that no nulls are allowed in the columns for that index? How can this be so if null is by definition undefined and has no equivalence?
Rekaish Bhardwaj wrote: > > > Does a unique index mean that no nulls are allowed in the columns for that > index? > Nope. > > A single null is allowed. > The unique index will only allow one undefined record. > > > How can this be so if null is by definition undefined and has no > equivalence? > Relational theory states that null is never equal to any other null ( probably why you get IS NULL, and not = NULL ... ), but implementations tend not to bother with the additional headaches that this would cause ( they just use some obscure value to indicate null) .... and thus only one null in a unique index. Cheers James