Choose a location:
posted 12/16/2009 by mohit kumar
In this blog I will explain Unique constraint in SQL.If i create a UNIQUE constraint, i can't insert duplicate data in that column.The UNIQUE constraint ensures that all values in a column are distinct.Example i have created a Table:-
CREATE TABLE UNIQUE_EXAMPLE ( ID INT UNIQUE, Name VARCHAR(50) )
INSERT INTO UNIQUE_EXAMPLE values ('1','Mohit'); INSERT INTO UNIQUE_EXAMPLE values ('2','Rahul'); INSERT INTO UNIQUE_EXAMPLE values ('3','Deepak');
INSERT INTO Customer UNIQUE_EXAMPLE('3','Monu');
What kind of email newsletter would you prefer to receive from CodeAsp.Net? 18