
Ultimate access to all questions.
In which of the following scenarios should a data engineer use the MERGE INTO command instead of the INSERT INTO command?
A
When the location of the data needs to be changed
B
When the target table is an external table
C
When the source table can be deleted
D
When the target table cannot contain duplicate records
E
When the source is not a Delta table
Explanation:
The MERGE INTO command (also known as UPSERT) is specifically designed for handling scenarios where you need to update existing records and insert new ones in a single operation. This is particularly important when the target table cannot contain duplicate records, as MERGE INTO allows you to:
Why other options are incorrect:
Key takeaway: Use MERGE INTO when you need to handle upsert operations (update existing records and insert new ones) to maintain data integrity and prevent duplicates in the target table.