| Author: UltimateRengan 28 Aug 2008 | Member Level: Diamond | Rating: Points: 4 |
hi, Primary key and unique are Entity integrity constraints.unique key can be null but primariy key cant be null. primariy key can be refrenced to other table as FK.We can declare only one primary key in a table but a table can have multiple unique key.
i hope this may help u
|
| Author: D.Jeya kumar(JK) 28 Aug 2008 | Member Level: Diamond | Rating: Points: 5 |
Hi,
One Primary key can created for a table and Many number of Unique key can be created on a table
Difference between this 2 is Primary will not allow Null values and duplicate values where as unique key will allow null values.
Primary key is automatically created when a clustered index is created
Primary key is used to identify a row uniquly so primary key should be created one for a table
Regards JK
|
| Author: http://venkattechnicalblog.blogspot.com/ 31 Aug 2008 | Member Level: Diamond | Rating: Points: 2 |
1 - primary key Unique key... as much as the number of columns.
Regards, Venkatesan Prabu .J http://venkattechnicalblog.blogspot.com/
|