Forum Discussion

Redraidas1's avatar
Redraidas1
Helper I
5 years ago
Solved

How to get TOP10

I'm trying to limit my DAX top give me the the SUM of TOP10 sales, however, DAX seems to be ignoring my TOP10 request and won't limit the caluclation to TOP 10 only. Any ideas? Thanks!   CALCULATE...
  • Anonymous's avatar
    Anonymous
    5 years ago

    Hi Redraidas1 ,

     

    You could consider to create a measure using RANKX() function.

    Then add this measure to filter to filter the data that rank value is less than 10.

    For example:

    _sum = SUM('Table'[value])
    
    _rank = RANKX(ALL('Table'),[_sum])

     

     

    Best Regards,

    Jay