Forum Discussion
Baseline month data measure
Hi,
Help me please. i need to create baseline volume info. baseline month is December 2023, yearly target will be 10% and i will need to check monthly basics to the results, so, how can i set Baseline volume?
i have used this measure but i get the all year data:
- Anonymous2 years ago
Hi Iculi
I tested your Dax and I came up with the problem:
You misplaced the brackets,
Here is the modified Dax:
Baseline Volume = CALCULATE( SUM('DateTable'[Volume]), FILTER( DateTable, YEAR(DateTable[Date])=2023 && MONTH(DateTable[Date])=12) )You can open the feature in the option,
so you can use this button to format the code for better inspection.
Best Regards,
Zhengdong Xu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
3 Replies
- AnonymousNot applicable
Hi Iculi
I tested your Dax and I came up with the problem:
You misplaced the brackets,
Here is the modified Dax:
Baseline Volume = CALCULATE( SUM('DateTable'[Volume]), FILTER( DateTable, YEAR(DateTable[Date])=2023 && MONTH(DateTable[Date])=12) )You can open the feature in the option,
so you can use this button to format the code for better inspection.
Best Regards,
Zhengdong Xu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- IculiFrequent Visitor
Hi Zhengdong Xu,
Thank you for your answer, i also find the solution but my formula a little bit different, in the FILTER part i have used different way: FILTER(DateTable,DateTable[Year]=2023 && (DateTable[Month_nr]=12)))
and it is also work. But i will use your version.. 🙂
Thank you for your help!
Icu
- Ritaf1983
Super User
Hi Iculi
Please provide sample data that covers your issue or question completely, in a usable format (not as a screenshot).
https://community.powerbi.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-...
Please show the expected outcome based on the sample data you provided.
https://community.powerbi.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly