Problem with DimAudit Table
2 posters
Page 1 of 1
Problem with DimAudit Table
Following on the ETL package sample on the book, I can't get the Master Extract Package to work on my own project. Running the first task, get AuditKey will send and error '[Execute SQL Task] Error: Executing the query "INSERT INTO [DimAudit]
(ParentAuditKey
..." failed with the following error: "The INSERT statement conflicted with the FOREIGN KEY SAME TABLE constraint "FK_dbo_DimAudit_ParentAuditKey". The conflict occurred in database "Test_DW", table "dbo.DimAudit", column 'AuditKey'.
The statement has been terminated.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly.
'
I checked both DimAudit tables, the one from the package and the one created by the Dimensional Model excel sheet, and both are identical.
Any Ideas?
(ParentAuditKey
..." failed with the following error: "The INSERT statement conflicted with the FOREIGN KEY SAME TABLE constraint "FK_dbo_DimAudit_ParentAuditKey". The conflict occurred in database "Test_DW", table "dbo.DimAudit", column 'AuditKey'.
The statement has been terminated.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly.
'
I checked both DimAudit tables, the one from the package and the one created by the Dimensional Model excel sheet, and both are identical.
Any Ideas?
moreno- Posts : 5
Join date : 2011-08-04
Re: Problem with DimAudit Table
In the Execute SQL Task Editor did you map a user variable to the PrentAuditKey parameter. Did you set that variable or provide a default value?
cjrinpdx- Posts : 51
Join date : 2011-07-14
Location : Portland, OR
Problem with DimAudit Table
Yes I did. Meanwhile I figure out the issue.
I used the script out of the dimensional excel sheet to create my Audit Table, well that will also build all FK needed between tables. I was developing on a table by table mode. What needs to be done is NOCHECK the FK on the DimAudit table until you finish developement. You can later CHECK that FK constraint back.
At leat that fix my issue.
Thanks.
I used the script out of the dimensional excel sheet to create my Audit Table, well that will also build all FK needed between tables. I was developing on a table by table mode. What needs to be done is NOCHECK the FK on the DimAudit table until you finish developement. You can later CHECK that FK constraint back.
At leat that fix my issue.
Thanks.
moreno- Posts : 5
Join date : 2011-08-04
Similar topics
» Bridge Table Problem in T-SQL
» Problem while Designing Fact table
» DimAudit AuditKey vs ParentAuditKey
» The age problem
» Help with Complex One-to-Many relationships
» Problem while Designing Fact table
» DimAudit AuditKey vs ParentAuditKey
» The age problem
» Help with Complex One-to-Many relationships
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum