Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Good morning,
I’ve been struggling for one DAX solution I can’t figure out how to write it.
I’m trying to find the latest purchase price based on the salesdate so I can calculate the Margin of a product on a given date.
I'm getting close with:
As you see, the Purchase_Price_Calculated on 31-jan should be 49, however it's showing 56. It's not giving the last date in the filter.
I'm missing the final piece in this puzzle.
Any help will be appreciated.
Michel
Solved! Go to Solution.
I was able to solve it myself with the following code:
I was able to solve it myself with the following code:
HI
Try this
Hi Semja,
Unfortunatly both solutions give the same wrong result.
Regards
Michel
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 |
---|---|
14 | |
11 | |
10 | |
10 | |
9 |
User | Count |
---|---|
18 | |
13 | |
12 | |
11 | |
8 |