Forum Discussion
CliffordAP
4 years agoHelper II
Power Query - Custom Column tracking when the value of another column changes
Hello all! I have a small question. Is there a way I can create a custom column that will numerically add 1 each time the value of another column changes? A A A B B C A A ...
- Anonymous4 years ago
You can first sort like you have it, then Table.Buffer, then Group By Column1 and add an All Rows aggregation--but then go back to that step and add the optional parameter GroupKind.Local.
From there, you can add an index column starting at 1. Then Remove the columns except the table column and the index column. Now expand the table column, and you are all set.
--Nate
Anonymous
4 years agoNot applicable
You can first sort like you have it, then Table.Buffer, then Group By Column1 and add an All Rows aggregation--but then go back to that step and add the optional parameter GroupKind.Local.
From there, you can add an index column starting at 1. Then Remove the columns except the table column and the index column. Now expand the table column, and you are all set.
--Nate