SCD2 + Merge Statement + SQL Server
- by Nev_Rahd
I am trying work out with MERGE statment to Insert / Update Dimension Table of Type SCD2
My source is a Table var to Merge with Dimension table.
My MERGE statement is throwing an error as:
The target table
'DM.DATA_ERROR.ERROR_DIMENSION' of the
INSERT statement cannot be on either
side of a (primary key, foreign key)
relationship when…