Re: unique constraint/index

Tech-Archive recommends: Fix windows errors by optimizing your registry

From: Tom Moreau (tom_at_dont.spam.me.cips.ca)
Date: 10/25/04


Date: Mon, 25 Oct 2004 09:59:18 -0400

The main difference is that you can have a foreign key reference the unique
constraint's key (s) but you can't do this with the plain vanilla unique
index.

-- 
Tom
---------------------------------------------------------------
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Columnist, SQL Server Professional
Toronto, ON Canada
www.pinnaclepublishing.com
"Michael Zdarsky" <zdarsky@zac-it.com.(nospamplease)> wrote in message
news:E4170281-32E2-468D-BD40-33914597E705@microsoft.com...
nHello,
what is the difference between:
alter table T1
add constraint C1 unique nonclustered (COL1)
and
create unique index I1 ON T1(COL1)
Thank you
Michael
--