Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Error creating relationship between tables
Message
 
 
To
All
General information
Forum:
Microsoft SQL Server
Category:
Database design
Title:
Error creating relationship between tables
Environment versions
SQL Server:
SQL Server 2005
Miscellaneous
Thread ID:
01091947
Message ID:
01091947
Views:
52
In the database diagram tool, I am attempting to creat a relationship betwen two tables. When I look at the constraints for both tables, I there are none listed. Clinserv is the parent table with a 1 to many relationship with the child table clinsdet. Clinsdet.fk_clinserv is a field with an index on it (IE the foreign key). I want to relat this to clinserv.id which is a primary key. I can drap clinsdet.fk_clinserv and drop it onto clinserv.id. When I save the diagram I get the following error.
'clinserv' table saved successfully
'clinsdet' table
- Unable to create relationship 'FK_clinsdet_clinserv'.  
The ALTER TABLE statement conflicted with the FOREIGN KEY constraint "FK_clinsdet_clinserv". The conflict occurred in database "ecpvgh", table "dbo.clinserv", column 'id'.
Next
Reply
Map
View

Click here to load this message in the networking platform