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
ttcalendar
Frequent Visitor

Compare Forecast Version

Hello,

 

Every month we release a new revised forecast for our sales person to populate forward forecast numbers. I have another table which actual sales come through. When sales actualise, I need to calculate the variance between the previous month forecast and the actual sales but, then show for the following months, the revised forecast value to show the delta (difference row). 
I have slicer that shows the latest forecast version, eg, 202403 FC Version. 

 

Below are is an example snapshot what I'm looking for and the forecast table. 

 

 

Your help is much appreciated.

 

ttcalendar_2-1708512201244.png

 

 

ttcalendar_0-1708511832261.png

 

5 REPLIES 5
ttcalendar
Frequent Visitor

Hi @v-rzhou-msft,

 

Thanks for the help! Much appreciated.

 

Instead of hard coding the forecast version in the calculate measures, I would like to present the user the option to select from 2 slicers to select the forecast versions they want to compare. 

 

How can I incorporate this?

Hi @ttcalendar ,

 

I am confused about what your table looks like. Is Actual data and Forecast data in different tables like my sample or in the same table?

Your calculation is based on your data model. Please share a sample file with me.

 

Best Regards,
Rico Zhou

 

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

Hi @v-rzhou-msft 

Apologies, the actuals and forecasta data are in different tables like yours. Attached is a sample.  

 

Sample PBI 

 

v-rzhou-msft
Community Support
Community Support

Hi @ttcalendar ,

 

Due to I don't know your data model, I create a sample to have a test.

Forecast Table:

vrzhoumsft_0-1708591884566.png

Fact Table:

vrzhoumsft_1-1708591890371.png

Relationship:

vrzhoumsft_2-1708592065200.png

Measures:

202402 FC Version = CALCULATE(SUM('Table'[Forecast]),FILTER('Table','Table'[FC Version] = "202402 FC Version"))
202403 FC Version = CALCULATE(SUM('Table'[Forecast]),FILTER('Table','Table'[FC Version] = "202403 FC Version"))
Acutual = CALCULATE(SUM(Fact[Sales]),FILTER(ALL('Fact'),Fact[Month] = MAX('Table'[Month])))
Difference = 
IF([Acutual] = BLANK(),[202403 FC Version] - [202402 FC Version] ,[Acutual] - [202402 FC Version])

Result is as below.

vrzhoumsft_3-1708592116807.png

 

Best Regards,
Rico Zhou

 

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

 

 

Thanks for the help! Much appreciated.

 

Instead of hard coding the forecast version in the calculate measures, I would like to present the user the option to select from 2 slicers to select the forecast versions they want to compare. 

 

How can I incorporate this?

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.