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!View all the Fabric Data Days sessions on demand. View schedule
There must be a simple way but I can't find it
I have a date table joined to a fact table, and my date table stretches a long way before and after the dates in the fact table that determine the relationship
I have a measure, e.g. Measure = COUNT(Table[Fact]), and I want to return the maximum date, like this:
Month ¦ Week ¦ Measure ¦ Max Month ¦ Max Week
-------------------------------------------------------------
Jan 3 8 Feb 7
...
Feb 7 11 Feb 7
If I use ALLSELECTED, I get the last date in the date table, and I can't figure out how to limit it to the rows where the measure has a non-blank value
Any help much appreciated
Solved! Go to Solution.
Solved it another way
Hi, @Anonymous
Could you please tell me whether your problem has been solved?
If yes, you could accept the helpful answer as solution. For now, there is no content of description in the thread.
If you still need help, could you please share more details of your fact table to us.
Best Regards,
Community Support Team _ Eason
@Anonymous , Try measure like
Month =
var _max =maxx(all(Table), Table[Date])
return
COUNTX(filter(all(Table),Table[Date] =_max) ,Table[Month])
Week =
var _max =maxx(all(Table), Table[Date])
return
COUNTX(filter(all(Table),Table[Date] =_max) ,Table[Week])
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!