Databricks Certified Data Engineer Associate — Question 78

Which SQL keyword can be used to convert a table from a long format to a wide format?

Answer options

Correct answer: B

Explanation

The correct answer is B, PIVOT, which specifically allows the transformation of data from a long format to a wide format in SQL. The other options, such as TRANSFORM and CONVERT, do not serve this purpose, while SUM is an aggregation function that does not change the table structure.