Forum Discussion
THEG72
Helper V
8 years agoAdd Index Column which is repeated based on Group by Text field
Hi am looking to have an Index Column that will repeat the same index number if the AccoutantLinkCode is repeated in another text field column.
So for the first AccountantLinkCode group "Bank" the index would be 1, then next group AR would be 2 and so on..
Can you advise the best approach or function to get this new index column in the table below?
6 Replies
- Zubair_Muhammad
Community Champion
HI THEG72
Try this. First Add a supporting Column
Supporting Column = CALCULATE ( MIN ( Table1[Index] ), ALLEXCEPT ( Table1, Table1[AccountantLinkCode] ) )- Zubair_Muhammad
Community Champion
Then you can use this Index Column
Please see attached excel file
Index Column = RANKX ( Table1, Table1[SupportingColumn],, ASC, DENSE )
- THEG72
Helper V
Thanks for your reply, would you know the M language version to get this result instead of DAX?