The ultimate Microsoft Fabric, Power BI, Azure AI, and SQL learning event: Join us in Stockholm, September 24-27, 2024.
Save €200 with code MSCUST on top of early bird pricing!
Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
I thought this would be easy but it isn´t 😉
I want to build a measure showing the month to date sales of the current month.
The measure should ignore all filters that a user sets.
So today the measure should show the sales from Sep 1 to Sep 21 - no matter whatever the user does.
My approach was to combine TOTALMTD and ALL in a meaningful way, but it doesn't work.
This is what I have been trying to do: (AllSales is a measure)
SalesMTD =
TOTALMTD (
[AllSales],
ALL('MyCalendar'[Date]),
MONTH ( 'MyCalendar'[Date] ) = MONTH ( TODAY () )
)
The result is always blank.
I tried a couple of more things but without success.
Can anybody help?
Solved! Go to Solution.
I found a solution myself 🙂
It takes two steps now and maybe there is a (much) easier way.
First step:
SalesMTD =
CALCULATE (
[AllSales],
DATESMTD ( 'MyCalendar'[Date] )
)
Second step:
TodaysSalesMTD =
CALCULATE (
[SalesMTD],
'MyCalendar'[Date]
= TODAY ()
)
The value I show now on the card-visual is TodaysSalesMTD.
Hi @cosmicyes ,
Does that make sense? If so, kindly mark your answer as the solution to close the case please. Thanks in advance.
Best Regards
Community Support Team _ Polly
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
I found a solution myself 🙂
It takes two steps now and maybe there is a (much) easier way.
First step:
SalesMTD =
CALCULATE (
[AllSales],
DATESMTD ( 'MyCalendar'[Date] )
)
Second step:
TodaysSalesMTD =
CALCULATE (
[SalesMTD],
'MyCalendar'[Date]
= TODAY ()
)
The value I show now on the card-visual is TodaysSalesMTD.
Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.
Check out the August 2024 Power BI update to learn about new features.
Learn from experts, get hands-on experience, and win awesome prizes.
User | Count |
---|---|
116 | |
81 | |
81 | |
48 | |
41 |
User | Count |
---|---|
149 | |
110 | |
66 | |
64 | |
56 |