Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
Hi
Need help with filters applied to DAX
When the filter version "Actual" is selected the fomula below works, it returns that last date of actual sales reported
LastActMonth = CALCULATE(max ('fact Sales'[Calendar Day]),'fact Sales'[Version]="Actual")
But I must have it working also when the Budget Version is selected in the filter visual
Appreciate help on this
kr, Elad
Solved! Go to Solution.
Hi @EladAppelNN ,
You can use the following DAX:
Measure =
MAXX(
ALLSELECTED('fact Sales'),[Calendar Day])
The Allselected() function calculates based on the data you filter on visual
Refer to:
ALLSELECTED function (DAX) - DAX | Microsoft Learn
If the results don't meet your expectations, can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data. We can better understand the problem and help you
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @EladAppelNN ,
Try using the below calcultion. I just modified your calculation a little bit.
If I answered your question please give kudos and accept it as a solution!
Thanks
Hi @EladAppelNN ,
You can use the following DAX:
Measure =
MAXX(
ALLSELECTED('fact Sales'),[Calendar Day])
The Allselected() function calculates based on the data you filter on visual
Refer to:
ALLSELECTED function (DAX) - DAX | Microsoft Learn
If the results don't meet your expectations, can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data. We can better understand the problem and help you
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @EladAppelNN
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/1447523
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
81 | |
75 | |
60 | |
37 | |
33 |
User | Count |
---|---|
101 | |
56 | |
51 | |
45 | |
40 |