what is the different between unique+not null & primary key,

Answer Posted / suresh babu

Unique:

Unique is a constraint,which doesn't allow the duplicate
values and allow only one null value.We can create more
number of unique constraint in single table.

Not Null:

Not Null constraint,which doesn't allow the Null values and
allow the duplicate values.

Primary Key:

We can create one primary key for a table,Which doesn't
allow the duplicate and null values,and used for make a
foreign key relation.we can't do this process using above
two constraints.

Is This Answer Correct ?    4 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is left join in postgresql?

809


Explain the advantages and disadvantages of stored procedure?

890


What is sql partition?

798


What is sql in java?

807


If a cursor is open, how can we find in a pl/sql block?

928


How do I access sql anywhere database?

716


What is pl sql variable?

741


What is crud sql?

759


how to load data files into tables with 'mysqlimport'? : Sql dba

817


What is coalesce sql?

759


How do I create a memory optimized filegroup?

744


what are all types of user defined functions? : Sql dba

816


What is a clob in sql?

773


Is sql port 1433 encrypted?

808


Are null values same as that of zero or a blank space?

776