Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

primary key

0 views
Skip to first unread message

my

unread,
Sep 27, 2002, 3:09:24 PM9/27/02
to
Would any DBA recommend to set up primary keys on tables with space or
null?

Thanks
Mike


my

unread,
Sep 27, 2002, 3:09:25 PM9/27/02
to

Blair Kenneth Adamache

unread,
Sep 27, 2002, 4:26:03 PM9/27/02
to
DB2 does not support nulls in primary keys.

Rhino

unread,
Sep 27, 2002, 4:33:23 PM9/27/02
to
A primary key cannot ever contain a null. If the primary key contains more
than one column, none of the columns in the key may contain a null.

As for using a space in a primary key, it wouldn't make much sense normally.
However, it could conceivably be a reasonable thing to do in some very
special situation.

Rather than looking for a blanket rule that you should or shouldn't do
something, it would be better for you to explain why you think you want a
blank in a primary key and then ask if the other readers of this group can
think of a better approach.

Rhino
"my" <m...@att.net> wrote in message
news:F12l9.69730$jG2.3...@bgtnsc05-news.ops.worldnet.att.net...

0 new messages