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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
aqeel
Regular Visitor

need help in unpivoting forecasted values based on weeks

I have two tables forecasted values and actual values, 
forecasted table has data in one row with all 4 or 5 weeks you can see in the screen shot below. I am facing problem to unpivot this data while unpivoting matches does not match.
aqeel_0-1715952932944.png
Actual table has values in one column and date in a separate column, I need to make forecasted table in same grain to make relationship and create visuals actual value vs forecast values. 

aqeel_1-1715953012535.png
@mh2587

 

 

 

1 REPLY 1
v-yohua-msft
Community Support
Community Support

Hi, @aqeel 

Select the column that represents the week. Right-click the selected column and select Unpivot Columns, or go to the Transform tab and select Unpivot Other Columns. This creates two new columns: one for the number of weeks (for example, WeekNumber) and one for the corresponding value (for example, Value). Rename columns as needed.

You can check the following link to learn more about Unpivot:

Perform common query tasks in Power BI Desktop - Power BI | Microsoft Learn

 

How to Get Your Question Answered Quickly 

Best Regards

Yongkang Hua

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

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