Hi there,
I have a data integration job with just one mapping: for EcomVariantOptions. I also have the option "Remove missing rows after import" turned on. Yesterday, the job failed (I think because I had a weird ID in my source) and then got the following error:
Job Failed with the following message: Failed to remove rows from Table [dbo.EcomLanguages] that where not present in source. Exception message: The DELETE statement conflicted with the REFERENCE constraint "EcomValidationGroupsTranslation_FKLanguageID". The conflict occurred in database "database", table "dbo.EcomValidationGroupsTranslation", column 'EcomValidationGroupsTranslationValidationGroupLanguageID'. The statement has been terminated. Sql query: DECLARE @r INT; SET @r = 1; WHILE @r > 0 BEGIN Delete top(100000) from [dbo].[EcomLanguages] where not exists (select * from [dbo].[EcomLanguagesTempTableForBulkImport] where ([dbo].[EcomLanguages].[LanguageId]=[LanguageId] or ([dbo].[EcomLanguages].[LanguageId] is null and [LanguageId] is null)) ) SET @r = @@ROWCOUNT; END
Why is it trying to deleted from Languages even though these aren't mapped? That looks very scary to me.
Imar