1
votes

I have a table Like this,

Table1

enter image description here

I want to create a column called as Row Number using DAX and not Query Editor (M).

So the Expected output is,

enter image description here

This can be done in M - Power Query Side.

But, I am looking for a solution using DAX- Calculated Column.

Additional source data

enter image description here

1

1 Answers

0
votes

The RANKX function should work fine for this purpose.

Row Number = RANKX ( Table1, Table1[ColA] )

Recommended reading:

https://radacad.com/how-to-use-rankx-in-dax-part-1-of-3-calculated-columns