Difference between primary key and unique key ?

Answer Posted / chintan desai

Primary key don't have any null value, each table have only
one primary key. Not support duplicate value.

Unique key is uniquely identify, more then one unique key
allow in table.

Here the main different is what primary key do not have any
null value where unique key have only one null value.

Ex: here t1 is the name of table which have two field id and
name. here id is identify as a unique key then unique key's
null value look like under bellow:

1 chintan
NULL komal
2 ck
NULL NULL

Is This Answer Correct ?    2 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can group functions be used in the order by clause in oracle?

580


What is SQL Tuning Advisor in Oracle?

635


What do database buffers contain?

567


What is an oracle wallet?

515


What are the logical operations?

677






Is oracle the best database?

522


What is the difference between a hot backup and a cold backup in oracle?

577


What is oracle server autotrace in oracle?

616


How to name query output columns in oracle?

692


How would you best determine why your MVIEW couldnt FAST REFRESH?

1438


How to rename an index in oracle?

619


Explain the use of owner option in exp command.

569


How to best split csv strings in oracle 9i?

591


What is the difference between view and materialized view in Oracle?

611


What is a lookup table in oracle?

542