Medium severitydata integrity
Power BI Refresh Error:
2601
What does this error mean?
An INSERT violated a unique index — a row with the same key already exists in the table.
Common causes
- 1A non-constraint unique index is violated by duplicate source data
- 2Pipeline retried after a partial success, re-inserting already-loaded rows
- 3Source system sent duplicate records in the same batch
How to fix it
- 1Step 1: Identify the index and duplicate value from the error message. Find duplicates: SELECT <indexed_columns>, COUNT(*) FROM <table> GROUP BY <indexed_columns> HAVING COUNT(*) > 1;
- 2Step 2: Deduplicate the source before loading: use a CTE with ROW_NUMBER() to keep only the first occurrence per key.
- 3Step 3: For ADF, enable upsert mode in the sink to handle re-runs gracefully — specify the unique index columns as the key.
Frequently asked questions
Official documentation: https://learn.microsoft.com/en-us/sql/relational-databases/errors-events/mssqlserver-2601-database-engine-error