nerdexam
Microsoft

DP-203 · Question #114

Drag and Drop Question You have an Apache Spark DataFrame named temperatures. A sample of the data is shown in the following table. You need to produce the following table by using a Spark SQL query.

Sign in or unlock DP-203 to reveal the answer and full explanation for question #114. The question stem and answer options stay visible for context.

Submitted by cyberguy42· Mar 30, 2026Transform and process data using Apache Spark SQL - specifically reshaping tabular data using PIVOT, type conversion with CAST, and string collation with COLLATE, commonly tested in Azure Data Engineer Associate (DP-203) or Databricks certifications.

Question

Drag and Drop Question You have an Apache Spark DataFrame named temperatures. A sample of the data is shown in the following table. You need to produce the following table by using a Spark SQL query. How should you complete the query? To answer, drag the appropriate values to the correct targets. Each value may be used once more than once, or not at all. You may need to drag the split bar between panes or scroll to view content. NOTE: Each correct selection is worth one point. Answer:

Exhibits

DP-203 question #114 exhibit 1
DP-203 question #114 exhibit 2

Answer Area

Drag items

CASTCOLLATECONVERTFLATTENPIVOTUNPIVOT

Unlock DP-203 to see the answer

You've previewed enough free DP-203 questions. Unlock DP-203 for full answers, explanations, the timed quiz mode, progress tracking, and the master PDF. Question stem and options stay visible so you can still see what's on the exam.

Topics

#Spark SQL#PIVOT#DataFrame transformations#Data reshaping
Full DP-203 Practice