Databricks Certified Data Engineer Associate — Question 61
Which command can be used to write data into a Delta table while avoiding the writing of duplicate records?
Answer options
- A. DROP
- B. INSERT
- C. MERGE
- D. APPEND
Correct answer: C
Explanation
The MERGE command is specifically designed to handle updates and inserts into a Delta table, making it effective at preventing duplicates by matching existing records. The DROP command removes data, INSERT adds records without checks for duplicates, and APPEND adds data at the end, which does not account for existing entries.