Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
I want to write a measure to return the most current value for an asset based on the last date available:
| Table1 | ||
| Asset ID | Value | Period |
| A | 1500 | 1-Dec-20 |
| A | 4500 | 1-Mar-21 |
| A | 2000 | 1-Jun-21 |
| B | 500 | 1-Dec-20 |
| B | 150 | 1-Mar-21 |
| B | 100 | 1-Jun-21 |
| C | 600 | 1-Dec-20 |
| C | 1000 | 1-Mar-21 |
| C | 900 | 1-Jun-21 |
| Result | ||
| Asset Id | Current Value | Period |
| A | 2000 | 1-Jun-21 |
| B | 100 | 1-Jun-21 |
| C | 900 | 1-Jun-21 |
Solved! Go to Solution.
@shelleye This is Lookup Min/Max, like this:
Measure Lookup Max Simple =
VAR __Table = 'Table1'
VAR __Max = MAXX(__Table,[Period])
RETURN
MAXX(FILTER(__Table,[Period] = __Max),[Value])
@shelleye No problem, I actually grabbed that from my test PBIX for my external tool, Microsoft Hates Greg's Quick Measures. I have 4 different lookup min/max formulas in there that make these kinds of calculations a breeze.
@shelleye This is Lookup Min/Max, like this:
Measure Lookup Max Simple =
VAR __Table = 'Table1'
VAR __Max = MAXX(__Table,[Period])
RETURN
MAXX(FILTER(__Table,[Period] = __Max),[Value])
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 104 | |
| 81 | |
| 66 | |
| 50 | |
| 45 |