Interview practice question
Duplicates after reprocessing
Data Engineering · Snowflake · Intermediate
After a pipeline failure and rerun, you find duplicate rows in your target table. How do you fix it now and prevent it in future?
What a strong answer covers
Your AI report card counts how many of these ideas you cover.
- Identify duplicates using business keys and load timestamps.
- Clean with a deduplicated rebuild using QUALIFY ROW_NUMBER().
- Make loads idempotent with MERGE on business keys instead of INSERT.
- Or use delete-then-insert for a partition like a date.
- Add a uniqueness test that fails the pipeline.
Practise this topic
Start without signing up. Sign in free to get an AI report card on your answer.