Forum Discussion
abelrmg
Helper II
6 years agoHELP INDEX COLUMN WITH RANGES
I have a two columns "JOB" and "ROL", Job is a incremental number and "ROL" this could be "A","B" or "C". And I would like to add a column like index considering how many equals roles there are for e...
parry2k
Super User
6 years agoabelrmg add an index column in query editor and then add following column and it will get you what you are looking for
Index Result =
RANKX (
FILTER(
What,
What[Job]= EARLIER ( What[Job] ) &&
What[ROL] = EARLIER ( What[ROL] )
),
What[Index], , ASC, Dense
)
abelrmg
Helper II
6 years agoparry2k , thank you for your suggestion it works, but is there sometihing similar in Power Query?, beacuse then i want to create a pivot table and the values are dynamics and this does not work in DAX.
Regards
- parry2k6 years ago
Super User
Not sure what you mean by dynamic, it should work. May be I am missing something.- abelrmg6 years ago
Helper II
parry2k It was my mistake, I forgot to mention that I was looking for the solution via Power Query, because then I will use that column to make a pivot table to perform some like this:
Job ROL A1 ROL A2 ROL B1 ROL B2 ROL B3 ROL C1 1 Name 1 Name 2 Name 3 Name 4 2 NAME 5 NAME 6 NAME 7 3 NAME 8 NAME 9 NAME 10 NAME 11 NAME 12 Regards