Environment:
- SQL Server Katmai
- SQL Samples
Repro Steps:
- Open ‘<SampleRoot>\ Tools\Samples\AdventureWorks LT\ AdventureWorksLT.vsd’ via Visio
- Check Name of Relation between Tables ‘Customer’ and ‘CustomerAddress’
- Select the associated Foreign Key’s Name in DB ‘AdventureWorks LT’:
select name from sys.foreign_keys
where parent_object_id=(select object_id from sys.tables where name='CustomerAddress')
and referenced_object_id=(select object_id from sys.tables where name='Customer')
- Compare the two names
Expectation:
The two Names should be the same
Actual Result:
The two names are not the same.
The Name in Visio is ‘Customer_CustomerAddress_FK1’
The Name in real DB is ‘FK_CustomerAddress_Customer_CustomerID’
Actually, all foreign key’s names in Visio are not the same with it in real DB. The Visio file should be updated.