Databricks Certified Data Engineer Associate · Free Practice Question Medium

Question 16

In which of the following scenarios should a data engineer use the MERGE INTO command instead of the INSERT INTO command?
  • A When the source table can be deleted
  • B When the location of the data needs to be changed
  • C When the target table is an external table
  • D When the source is not a Delta table
  • E When the target table cannot contain duplicate records
Reveal correct answer

Correct answer: E

Explanation

The MERGE INTO command is used when a data engineer needs to ensure that the target table does not contain duplicate records. It allows for efficient upsert operations, enabling updates, inserts, and deletes while maintaining data integrity. This command is particularly valuable in scenarios where preventing duplicate entries in the target table is crucial, ensuring that data remains accurate and consistent. Other factors, such as the source table being deletable or the location of the data, are not as critical in determining the use of MERGE INTO as the requirement to manage duplicates.

Discussion

Think the marked answer is wrong, or have a better explanation? Share it below — comments appear after review.

You must be logged in to post a comment.

Preparing For

Your Certification?

255+ certifications
Detailed explanations
Free PDF samples

Has All The Questions You Need