What's the difference between a primary key and a unique key?
Answer Posted / sunil
HI ALL
IN CASE OF INSERTING REPETED NULL IN UNIQUE KEY COLOUMN ,
IF IT IS COMPOSITE KEY IS POSSIBLE. . . ANY LOGICAL RESON?
Eg:
CREATE TABLE TRY(ROLL NUMBER,LIB_CARD_NO NUMBER,
CONSTRAINT CON_UNQ UNIQUE(ROLL,LIB_CARD_NO));
INSERT INTO TRY VALUES(NULL,NULL);
--> 1 ROW CREATED
INSERT INTO TRY VALUES(NULL,NULL);
--> 1 ROW CREATED -- REPETED NULL ARE ALLOWED!!!!
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What is for xml in sql server?
Explain the difference between delete,drop and truncate in SQL Server?
How to check table values in sql server?
What objects does the fn_my_permissions function reports on? : sql server security
How sql server executes a statement with nested subqueries?
What is check constraint in sql server?
Can we insert data into view sql server?
When you use @@error and try-catch?
What the different components in replication and what is their use?
what is create database syntax? : Sql server database administration
What is lock escalation? : sql server database administration
what are the disadvantages of cursors? : Sql server database administration
What the class forname () does?
How to create new databases with "create database" statements?
Do you know what are the reporting services components?