cancel
Showing results 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.

Frequent Visitor

## Cumulative values per month

Hi everyone,
I have a target goal sale for each saler in my company in 2022, I would like to calculate cumulativetarget line for each person. I have this picture for your reference. Please help me to calculate it. Thank you so much

1 ACCEPTED SOLUTION
Super User

@chinh_ho , if you have a date with help from a date table

example

Cumm Sales = CALCULATE(SUM(Sales[Sales Amount]),filter(all('Date'),'Date'[date] <=max('Date'[date])))

or

Cumm Sales = CALCULATE(SUM(Sales[Sales Amount]),filter(allselected('Date'),'Date'[date] <=max('Date'[date])))

You can create date from month and year

Date = Date([year],[month],1)

4 REPLIES 4
Super User

@chinh_ho , if you have a date with help from a date table

example

Cumm Sales = CALCULATE(SUM(Sales[Sales Amount]),filter(all('Date'),'Date'[date] <=max('Date'[date])))

or

Cumm Sales = CALCULATE(SUM(Sales[Sales Amount]),filter(allselected('Date'),'Date'[date] <=max('Date'[date])))

You can create date from month and year

Date = Date([year],[month],1)

Frequent Visitor

Hi amitchandak,
Thank you so much for your response. I can not use SUM function, because it is a single value. For example : Target sale in DimSaler in 2022

Micheal: \$100,000

Jack: \$120,000
My purpose is to have a cumulative target line by month to compare with actual sale.

Thank you

Super User

@chinh_ho , do you have a yearly target and you want to show that cummulative

refer

Distributing/Allocating the Yearly Target(Convert to Daily Target): Measure ( Daily/YTD): Magic of CLOSINGBALANCEYEAR With TOTALYTD/DATESYTD: https://community.powerbi.com/t5/Community-Blog/Power-BI-Distributing-Allocating-the-Yearly-Target-C...

If this does not help
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.

Frequent Visitor

Thank you so much for your quick response. I got a solution.

Announcements

#### 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

#### Power BI Monthly Update - April 2024

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

#### Fabric Community Update - April 2024

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

Top Solution Authors
Top Kudoed Authors