I want to create a Foreign key constraint on A Non -Primary key column of table. is it possible in sql server. when i am doing so i am getting error There are no primary or candidate keys in the referenced table '<table name>' that match the referencing column list in the foreign key 'fk_name'. reply quickly.......................................... Regards Sudipta K. Ghosh
If not a Primary Key, then the other option for a foreign key is that the parent column(s) has (have) a UNIQUE index. It's purely logical for foreign keys: the key must be unique, like a key for a lock.