Unpivot Table in Power BI
Power BI Unpivot table option converts selected columns into rows. Let us see how to create an Unpivot table or how to convert the pivot table into the unpivot table in Power BI with an example.
How to create unpivot Table in Power BI
To create or convert pivot to unpivot table, please click the Edit Queries option under the Home tab.
Clicking the Edit Queries option opens a new window called Power BI Power Query Editor.
In this Unpivot Table example, we are going to unpivot the columns 2005, 2006, 2006, and 2007.
There are a couple of ways to unpivot table
The First approach to unpivot table in Power BI
Please select the columns that you don’t want to unpivot, or you want to keep them unchanged will open the context menu. Select the Unpivot Other Columns option. This unpivots all the columns except the selected ones.
Now you can see the unpivoted table
The second approach to unpivot table in Power BI
Please select the columns that you want to unpivot will open the context menu. Select Unpivot Only Selected Columns option. This unpivots all the selected columns.
Now you can see the unpivoted table
The third approach to unpivot table in Power BI
In order to convert the pivot table into the unpivot table, go to Transform Tab. Under this tab, you can find the Unpivot Column button as shown below.
Use the drop-down list to unpivot the table. For the Unpivot Table demonstration purpose, we selected the Product ID, and Name columns, and then selected the Unpivot Other columns option.
Now you can see the unpivoted table.
We renamed the columns to more meaningful ones. Next, hit the Close & Apply option under the Home tab to apply these changes.
From the screenshot below, you can see the unpivot columns on the right side.