Forum Discussion
KPI visual does not accumulate
- Anonymous2 years ago
Hi RoHa ,
Please try:
Here's the example data I created:
Date
Sales Budget
MonthName
2024-01-01
100
January
2024-02-01
100
February
2024-03-01
100
March
2024-04-01
100
April
2024-05-01
100
May
2024-06-01
100
June
2024-07-01
100
July
Create a Measure:
Accumulated Sales Budget = VAR SelectedMonths = VALUES('ANT - Date'[Month]) RETURN IF( ISFILTERED('ANT - Date'[Month]), CALCULATE( SUM('ANT - Budget'[Sales Budget]), 'ANT - Budget'[MonthName] in SelectedMonths ), 0)The final page visualization is shown below:
I would be grateful if you could provide me with the pbix file or sample data.
Remember to remove sensitive data and do not log in to your account in Power BI Desktop when uploading the pbix file.
If you have any other questions please feel free to contact me.
The pbix file is attached.
Best Regards,
Yang
Community Support TeamIf there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
Hi RoHa ,
Please try:
Here's the example data I created:
|
Date |
Sales Budget |
MonthName |
|
2024-01-01 |
100 |
January |
|
2024-02-01 |
100 |
February |
|
2024-03-01 |
100 |
March |
|
2024-04-01 |
100 |
April |
|
2024-05-01 |
100 |
May |
|
2024-06-01 |
100 |
June |
|
2024-07-01 |
100 |
July |
Create a Measure:
Accumulated Sales Budget =
VAR SelectedMonths = VALUES('ANT - Date'[Month])
RETURN
IF(
ISFILTERED('ANT - Date'[Month]),
CALCULATE(
SUM('ANT - Budget'[Sales Budget]),
'ANT - Budget'[MonthName] in SelectedMonths
),
0)
The final page visualization is shown below:
I would be grateful if you could provide me with the pbix file or sample data.
Remember to remove sensitive data and do not log in to your account in Power BI Desktop when uploading the pbix file.
If you have any other questions please feel free to contact me.
The pbix file is attached.
Best Regards,
Yang
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!