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: Unique Key Constraint

Re: Unique Key Constraint

From: Greg <gregcpx_at_hotmail.com>
Date: 23 Jun 2006 09:15:44 -0700
Message-ID: <1151079344.524772.80390@b68g2000cwa.googlegroups.com>

  1. A table can only have 1 primary key (which is always unique)
  2. A table can have 1 or more unique index keys but still only 1 primary key.

-Greg
Khurram wrote:
> hi
>
> I read the following Unique key restriction
>
>
> -A table or view can have only one unique key.
>
> From
>
> http://download-west.oracle.com/docs/cd/B10501_01/server.920/a96540/clauses3a.htm
>
> But when i create more then one unique key it let me create is document
> pointing me wrong
> or i am getting wrong inference?
>
> SQL> DROP TABLE t;
>
> Table dropped.
>
> SQL> CREATE TABLE t (a NUMBER UNIQUE,b NUMBER UNIQUE);
>
> Table created.
>
> Khurram
Received on Fri Jun 23 2006 - 11:15:44 CDT

Original text of this message

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