What did I learn today? Power Query Unpivot Other Columns

This is a log of what I explore and learn.

Power Query – Unpivot Other Columns

Earlier I wrote an article about the Unpivot feature of Power Query:
Crosstab data consolidation using Power Query

The concept is simple but powerful. Consider the data… It is already imported into Power Query. This is a cross-tab. I want simple tabular data containing three columns: Country, Year and Consumption.

image

This is done by selecting all the year columns and then right click to choose the UNPIVOT option. Recently, Power Query team updated few features. Unpivot was one of them.

The data I have is from 1965 to 2012. Imaging the trouble you have to take to just select so many columns. Therefore, the Power Query team smartly added a new feature called Unpivot Other Columns. Note that this option is available in the drop down menu on the Transform ribbon. It is NOT available in the right click menu (context menu).

image

Now what do I need to do? Just select the First column and choose this option. Job done. Now we got data like this. (I have renamed the first column as country now).

image

Creating this information into a 3D map

Just to complete this topic, I will show you the output of this data shown using Power Map. In the upcoming articles, I will discuss Power Map in detail.

image

***

2 thoughts on “What did I learn today? Power Query Unpivot Other Columns

  1. Pingback: Knowledge Pack: Data Accuracy in Excel | Efficiency 365

  2. Pingback: Mega Quiz Winner and Correct Answers | Efficiency 365

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s