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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
afiqaz-97
Regular Visitor

How to show the cumulative value at the kpi chart

Hi, I have problem where by my KPI chart shown the recent value and not the cumulative value in the default value which refer to the picture below it shows the value for April and not the sum value of all months until April?. Can you give me some ideas how to figure out. Here are some of the attachment to help you visualise my problem.2.JPG

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @afiqaz-97 

Please correct me if I wrongly understood your question.

You said you want to sum value of all months until April , my understanding is that you want to compare the sum of all data from January to April last year with the sum of all data from January to April this year .Is it ?

You can create two measures to calculate the data of the first 4 months for last year and the data of the first 4 months for this year. And then add these measures in visual .

previous year = CALCULATE(SUM('Table'[Sales]),FILTER('Table','Table'[Date]>=DATE(YEAR(TODAY())-1,01,01) && 'Table'[Date]<DATE(YEAR(TODAY())-1,05,01)))

current year = CALCULATE(SUM('Table'[Sales]),FILTER('Table','Table'[Date]>=DATE(YEAR(TODAY()),01,01) && 'Table'[Date]<DATE(YEAR(TODAY()),05,01)))

 

Best Regards

Community Support Team _ Ailsa Tao

 

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

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

Hi @afiqaz-97 

Please correct me if I wrongly understood your question.

You said you want to sum value of all months until April , my understanding is that you want to compare the sum of all data from January to April last year with the sum of all data from January to April this year .Is it ?

You can create two measures to calculate the data of the first 4 months for last year and the data of the first 4 months for this year. And then add these measures in visual .

previous year = CALCULATE(SUM('Table'[Sales]),FILTER('Table','Table'[Date]>=DATE(YEAR(TODAY())-1,01,01) && 'Table'[Date]<DATE(YEAR(TODAY())-1,05,01)))

current year = CALCULATE(SUM('Table'[Sales]),FILTER('Table','Table'[Date]>=DATE(YEAR(TODAY()),01,01) && 'Table'[Date]<DATE(YEAR(TODAY()),05,01)))

 

Best Regards

Community Support Team _ Ailsa Tao

 

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

Ashish_Mathur
Super User
Super User

Hi,

This measure will calculate the YTD figure

=calculate([your measure],datesytd(calendar[date],"31/12"))

Hope this helps.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

3.JPG

 

I've try out and modified some because the calculate needs another function to read my data and column but it appear this error. Really appreciate for the help. Thanks in advance 

Hi,

You should close the SUM bracket before the first comma.  Also, the first inout of the DATESYTD() function should be Calendar[Date].  So you must first build a Calendar Table and create a relationship between the Date column of the RAW_RO table to the Date column of the Calendar Table.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.