Assume a Users table has ID and emailAddress columns though in reality it would have more. ID is a uniqueidentifier whereas emailAddress is nvarchar(256). I need to make sure both of these columns are unique. Also, this table is in a federation member database. How could I achieve this?
I'm getting the following error: "A unique or clustered index on a federated table must contain the federated column"
The federated column in my table is the ID column. Does it make sense to set the email address column as the primary key and the federated column?
just follow what the error tells you.
federated columns are required to be part of a unique or clustered index.
so, for your unique index, the columns should be Id+emailAddress
- Marked as answer by Iric WenModerator Thursday, September 27, 2012 6:53 AM