Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hello,
I am having a problem when trying to use TopN function.
I have this measure :
Hi @fhdalsafi
TOPN can return results in batches, returning all the first N rows of records that meet the conditions from a table. Its role is equivalent to a filter not a measure or column to calculate a value .
You can learn more through the link below .
https://docs.microsoft.com/en-us/dax/topn-function-dax
Best Regards
Community Support Team _ Ailsa Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@fhdalsafi , TOPN returns table that act as filter, Not meausre
Usages example
calculate([Measure], TOPN( 1,allselected(Table[Column]),[Measure],DESC), values(Table[column])))
refer if needed
TOPN: https://www.youtube.com/watch?v=QIVEFp-QiOk&list=PLPaNVDMhUXGaaqV92SBD5X2hk3TMNlHhb&index=42
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.