What is PIVOT and UNPIVOT in SQL?
Ask by Sumit Kesarwani
Updated 15 Sep 2020
A Pivot Table can automatically sort, count, and total the data stored in one table or spreadsheet and create a second table displaying the summarized data. The PIVOT operator turns the values of a specified column into column names, effectively rotating a table.
UNPIVOT table is reverse of PIVOT Table.