Forum Discussion

Yesvanth141's avatar
Yesvanth141
Frequent Visitor
7 years ago
Solved

DAX Row Number based on two columns (Calculated Column)

Hi All,

Thanks in Advance.

 

Guide me on this. 

 

DAX - Calculated Column(No Measure)

 

RowNumber/Rank based on Year-MMM and Customer by Amount desc

 

Monthwise customer rank/row number by Amount desc order 

 

 

 

  • Anonymous's avatar
    Anonymous
    7 years ago

    Hi,

     

    I may understand you correctly. I have 2 calculated columns for rank:

    Rank All column by amount:

    Rank All = (RANKX(Q3,Q3[Amount],,DESC,Skip))

     

    Another rank is by MonthYear:

    Rank by MonthYear = (RANKX(

                                                     FILTER(Q3,Q3[MonthYear] = EARLIER(Q3[MonthYear])),

                                                     Q3[Amount],,DESC,Skip))

     

     

    I hope this help and solve your problem. Thanks.

     

    Duc 

2 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi,

     

    I may understand you correctly. I have 2 calculated columns for rank:

    Rank All column by amount:

    Rank All = (RANKX(Q3,Q3[Amount],,DESC,Skip))

     

    Another rank is by MonthYear:

    Rank by MonthYear = (RANKX(

                                                     FILTER(Q3,Q3[MonthYear] = EARLIER(Q3[MonthYear])),

                                                     Q3[Amount],,DESC,Skip))

     

     

    I hope this help and solve your problem. Thanks.

     

    Duc 

  • v-danhe-msft's avatar
    v-danhe-msft
    Microsoft Employee

    Hi Yesvanth141,

    Could you please tell me if your problem has been solved? If it is, could you please mark the helpful replies as Answered?

     

    Regards,

    Daniel He