Exam DP-600 Topic 1 Question 60 Discussion

Actual exam question for Microsoft's DP-600 exam
Question #: 60
Topic #: 1
You have a Fabric tenant that contains lakehouse named Lakehousel. Lakehousel contains a Delta table with eight columns. You receive new data that contains the same eight columns and two additional columns.
You create a Spark DataFrame and assign the DataFrame to a variable named df. The DataFrame contains the new data. You need to add the new data to the Delta table to meet the following requirements:
* Keep all the existing rows.
* Ensure that all the new data is added to the table.
How should you complete the code? To answer, select the appropriate options in the answer area.

Suggested Answer:


Explanation:

o add new data to the Delta table while meeting the specified requirements:
* You should use the append mode to ensure that all new data is added to the table without affecting the existing rows.
* You should set the mergeSchema option to true to allow the schema of the Delta table to be updated with the new columns found in the DataFrame.
The completed code would look like this:
df.write.format("delta").mode("append")
option("mergeSchema", "true")
saveAsTable("Lakehouse1.TableName")

by Una at Jul 17, 2026, 01:22 AM

Comments

Chosen Answer:
This is a voting comment (?) , you can switch to a simple comment.
Switch to a voting comment New
Nick name: Submit Cancel
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

0
0
0
10