Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
evolu6ion
Frequent Visitor

Pivot, unpivot

Hello,

 

I have an excel file that looks like that:

SurveyIDColumn1Column2Which are available?For how long unavailable?Next delivery?Comments?Which are available?For how long unavailable?Next delivery?Comments?CreatedOnEditor
1Specific informationAvailable informationx1,x2,x3  some comments 3m-6m21.02.2018 01.01.2018x
2Specific informationAvailable information 24-48h21.02.2018 x1,x2,x3  some specific comments02.01.2018y
3Specific informationAvailable information 1w-1m22.03.2018some other commentsx1   03.01.2018u

 

And I'm trying to get to that:

SurveyIDColumn1Column2Which are available?For how long unavailable?Next delivery?Comments?CreatedOnEditor
1Specific informationAvailable informationx1nullnullsome comments01.01.2018x
1Specific informationAvailable informationx2nullnullsome comments01.01.2018x
1Specific informationAvailable informationx3nullnullsome comments01.01.2018x
1Specific informationAvailable informationnull3m-6m21.02.2018 01.01.2018x
2Specific informationAvailable informationnull24-48h21.02.2018 02.01.2018y
2Specific informationAvailable informationx1nullnullsome specific comments02.01.2018y
2Specific informationAvailable informationx2nullnullsome specific comments02.01.2018y
2Specific informationAvailable informationx3nullnullsome specific comments02.01.2018y
3Specific informationAvailable information 1w-1m22.02.2018some other comments03.01.2018u
3Specific informationAvailable informationx1nullnullnull03.01.2018u

 

 

So far in Power Query, I manage to get to that:

2019-02-13 14_58_42-Untitled - Power Query Editor.png

 

But when I try to use this method from this thread (https://community.powerbi.com/t5/Desktop/Unpivoting/m-p/443423#M204928), I get an error message :

2019-02-13 15_01_47-Untitled - Power Query Editor.png2019-02-13 15_02_03-Untitled - Power Query Editor.png

 

I have no idea on how to solve this issue.

 

Your help will be greatly appreciated, and do not hesitate to correct me or give any advice on how to do this more efficiently.

 

Thanks in advance!

N.

2 REPLIES 2
v-danhe-msft
Employee
Employee

Hi @evolu6ion,

Based on your desired table, I could not figure out how could you get [Which are available?] column?

It seemd you need to split the two [Which are available?] columns in your row table?

 

Regards,

Daniel He 

Community Support Team _ Daniel He
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi @v-danhe-msft 

 

Sorry for the delay of my feedback and thanks for your answer. Actually, we found a solution using modulo. Because in the original data, the [Which are available] and subsequent columns repeat for more than 180 times. Each time these 4 questions are repeated with different answers given, and each answers may contain multiple items that need to be splitted in order to connect to the original "product" table. When I got more time, I'll answer my thread with the aforementioned solution using modulo.

 

Regards.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.