Quantcast
Channel: SQL Server Master Data Services forum
Viewing all articles
Browse latest Browse all 1311

While copying current version (which is not committed) getting error: 547 for Insert statement conflict.

$
0
0

Following error we receive while copying current version.

547: The INSERT statement conflicted with the CHECK constraint “ck_tbl_5_8_HR_ChildType_ID”. The Conflict occurred in database “MDS_Production”, table “mdm.tbl_5_8_HR”., @errornumber = 547 , @errorprocedure = “ “,line 2 correlation ID: 7923e8be-e1fa-4ca9-a81d-e560b24deda9

I must say that if I copy any other version (which are validated) then I do not see any issue. I am successfully able to create a version.

Code for constraint:

USE [MDS_Production]

GO

ALTERTABLE [mdm].[tbl_5_8_HR] WITHCHECKADD CONSTRAINT [ck_tbl_5_8_HR_ChildType_ID]CHECK (([ChildType_ID]=(1)AND [Child_EN_ID]ISNOTNULLAND [Child_HP_ID]ISNULLOR [ChildType_ID]=(2)AND [Child_HP_ID]ISNOTNULLAND [Child_EN_ID]ISNULL))

GO

ALTERTABLE [mdm].[tbl_5_8_HR]CHECKCONSTRAINT [ck_tbl_5_8_HR_ChildType_ID]

GO

--I checked the mdm.tbl_5_8_HR table to make sure is there any record does not match with this condition.

I found the table population has all records in line with the constraint logic.

Following tables are the base to populate Child_EN_ID flag and Child_HP_ID flag in the  mdm.tbl_5_8_HR table.

[MDS_Production].[mdm].[tbl_5_8_HP]– Parent of Division Dimension Elements

[MDS_Production].[mdm].[tbl_5_8_EN]– Childe level elements of Division Dimension

I am new to MDS. Can anyone assist here on how to debug this error?

Please feel free if you need further information.

Thank You

Dharav



Viewing all articles
Browse latest Browse all 1311

Trending Articles



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