Quantcast
Channel: SQL Server Database Engine forum
Viewing all articles
Browse latest Browse all 12963

sys.foreign_keys is_not_trusted problem

$
0
0

Hello Forum,

I ran into difficult to explain situation with sys.foreign_keys.is_not_trusted value for 1 table.

3 times with not correct for this case statement: 'alter table drop constraint

then 'alter table create constraint and alter table check constraint'. To re-check this constraint, 2 'check' words required, scripts used wrongly just 1.

After 5 weeks, 3rd db was loaded with consolidated script at 1 time. Everything what was released to first 2 db's over the interval of 1 months was ran against 3rd db.

After sql comparison, 1st and 2nd db were identical and had constraint value sys.foreign_keys.is_not_trusted = 1 which was expected.

3rd db had sys.foreign_keys.is_not_trusted = 0.

Starting data for all 3 db's were the same and copied from prod. server.

Can anybody explain why 3rd had desired but not expected value 0? Does the value of foreign_keys.is_not_trusted have something to do with the interval of time?

if somebody from Microsoft have any insight explaining this unexpected behavior, it would be great.

Thank you for your time reading it.


gene


Viewing all articles
Browse latest Browse all 12963

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>