What's the difference between a primary key and a unique
key?
Answer Posted / swapna
Both primary key and unique enforce uniqueness of the
column on which they are defined. But by default primary
key creates a clustered index on the column, where are
unique creates a nonclustered index by default. Another
major difference is that, primary key doesn't allow NULLs,
but unique key allows one NULL only.
Is This Answer Correct ? | 16 Yes | 0 No |
Post New Answer View All Answers
What are database states in ms sql server?
How can we get count of the number of records in a table?
Explain syntax for disabling triggers?
What do you understand by sql server agent?
Why SQL Agent is used?
Explain trigger and its types?
How to use order by with union operators in ms sql server?
What are some examples of schemas?
Do you know the policy based administration feature of sql server 2008?
What are transactions and its controls?
How many null values we can have in a unique key field in sql server?
Explain transaction server distributed transaction?
Explain the truncate command?
What is side by side migration in sql server?
Call by value and call by reference in procedure and function, with NOCOPY.