[Solved] The DELETE statement conflicted with the REFERENCE constraint
When I try to load the data mart, i get the error message:
Error: 0x0 at Execute SQL Task: The DELETE statement conflicted with the REFERENCE constraint "FK_Monthly_Sales_Store". The conflict occurred in database "S20S308_DATAMART", table "dbo.F_Monthly_Sales", column 'ID_Store'.
Task failed: Execute SQL Task
You try to delete a table where a foreign key constraint exists. That means, another table contains data the references to the table you want to delete.
This is a common problem for beginners who want to delete a star schema. The fact table references to the dimension table. If you want to delete a dimension table where data in the fact table exits, you will get that error message.
Please read the error message, to see which table causes the problem in your DELETE statements.