Reply
Prabha45
Helper III
Helper III
Partially syndicated - Outbound

Data model - Unpivot

Hi All,

I have a table(data model) like the below. For every quarter there will be 2 new columns( Status and comments).
I tried unpivot the Q3, Q4 status in one table and in the other by Q3, Q4 comments. And merge these two tables but I did get the required table 2. What transformations I need to perform to get table 2.

CategorySub CategoryQ3- 2023 statusQ3- 2023 commentsQ4- 2023 status Q4- 2024 commentsOwner
RoadBikeIn progressWorkingIn progressN/ADavid
RoadCarIn progressUnder validationCompletedN/ASmith
ElectronicsPhoneIn progressWorkingCompletedN/AHenry
ElectronicsLaptopIn progressManufacturingIn progressManufacturingMicheal
ElectronicsHeadphonesIn progressN/ADelayedWorkingNeil
ClothesShirtIn progressTransportationDelayedReceived on MondayPeter
ClothesTrousersIn progressTransportationCompletedDoneChris


 Table 2 - 

CategorySub categoryQuarterStatusCommentsOwner
RoadBikeQ3-2023In progressWorkingDavid
RoadBikeQ4-2023In progressN/ADavid
RoadCarQ3-2023In progress Under validationSmith
RoadCarQ4-2023CompletedN/ASmith
ElectronicsPhoneQ3-2023In progressN/AHenry
ElectronicsPhoneQ4-2023CompletedWorkingHenry
ElectronicsLaptopQ3-2023In progressManufacturingMicheal
ElectronicsLaptopQ4-2023In progressManufacturingMicheal
ElectronicsHeadphonesQ3-2023In ProgressN/ANeil
ElectronicsHeadphonesQ4-2023DelayedWorkingNeil


Thanks in advance

1 ACCEPTED SOLUTION
Ahmedx
Super User
Super User

Syndicated - Outbound

Based on your description, I created data to reproduce your scenario. The pbix file is attached in the end.

Screenshot_2.png

 

View solution in original post

3 REPLIES 3
Ahmedx
Super User
Super User

Syndicated - Outbound

Based on your description, I created data to reproduce your scenario. The pbix file is attached in the end.

Screenshot_2.png

 

Syndicated - Outbound

Thank you very much. Can you please explain the grouped rows step

Jihwan_Kim
Super User
Super User

Syndicated - Outbound

Hi,

I am not sure if I understood your question correctly, but after unpivotting each table, please try APPEND function in Power Query Editor.

 

Append queries - Power Query | Microsoft Learn

 

 

 

If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Visit my LinkedIn page by clicking here.


Schedule a meeting with me to discuss further by clicking here.

avatar user

Helpful resources

Announcements
March PBI video - carousel

Power BI Monthly Update - March 2025

Check out the March 2025 Power BI update to learn about new features.

March2025 Carousel

Fabric Community Update - March 2025

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

Top Solution Authors (Last Month)
Top Kudoed Authors (Last Month)