
Answer-first summary for fast verification
Answer: PIVOT
The `PIVOT` keyword is used to rotate rows of a table by turning unique row values into separate columns, effectively converting the table from a long format to a wide format. This operation is particularly useful for data analysis and reporting purposes. Reference: [Databricks SQL Documentation](https://docs.databricks.com/sql/language-manual/sql-ref-syntax-qry-select-pivot.html)
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
No comments yet.