Difference between primary key and unique key ?

Answer Posted / deen dayal sharma

1. PRIMARY KEY & UNIQUE KEY both uniquely identity of each
row in a table.
2. BOTH keys will not contain repeated value.
3. One table may have more than one Unique Key Constraint But
it should have only one Primary Key Constraint column.
4. BUT UNIQUE KEY will contain NULL value but PRIMAY key will
not contain NULL value.

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to create an oracle testing table?

603


Where is the export dump file located?

577


Difference between hot backup vs. Cold backup?

615


How to omit columns with default values in insert statement in oracle?

584


What is truncate oracle?

537






What are the differences between primary key and unique key?

521


How to assign data of the deleted row to variables?

589


What is bulk copy or bcp in oracle?

618


How to convert times to characters in oracle?

614


How are extents allocated to a segment?

588


How to rename a tablespace in oracle?

629


How to insert a new row into a table in oracle?

599


Can we protect our pl/sql source code?

584


How can I convert single byte kana characters into multi byte kana characters and vice-versa.

1945


What is SQL Tuning Advisor in Oracle?

640