Forum Discussion
DAX - Average Daily Sales MTD
Hi Everyone,
I am trying to calculate ADS MTD using DAX queries. But unable to get accuracy value. I am sharing my file in this link.
Please help on this calculation.
Thanks in advance.
Regards
Venu
5 Replies
- amitchandak
Super User
venug , Try like example with help from date table
MTD = CALCULATE(Average(Sales[Sales Amount]),DATESMTD('Date'[Date]))
or
MTD = CALCULATE(AverageX(values('Date'[Date])Sales[Sales Amount]),DATESMTD('Date'[Date]))
- v-henryk-mstf
Community Support
Hi venug ,
For your formula, I did a test, just add an all function to the created ADSMTDmeasure, keep the external filter conditions, you can get the correct expected result.
ADSMTD = CALCULATE ( [ADS], DATESMTD ( Orders[Order Date] ), ALL ( Orders ) )
If the problem is still not resolved, please provide detailed error information and let me know immediately. Looking forward to your reply.
Best Regards,
Henry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.- venug
Helper II
Hi v-henryk-mstf ,
Thanks for you reply, i have already provided my desired output in given link. When i generate ADSMTD it should sum of all ADS values.
Please find below snippet for my desired output.
It's really great helpful to me, if will get solution for it.
Regards,
Venu