Sqlserver
 sql >> Database >  >> RDS >> Sqlserver

chiave univoca basata su 2 colonne in SQL Server 2008?

CREATE UNIQUE NONCLUSTERED INDEX IX_TableName_MfgID_CustNum ON TableName
(
        MfgID  ,
        Column2
) WITH( IGNORE_DUP_KEY = OFF)