Forum Discussion
Cul33
8 years agoFrequent Visitor
Assigning values to increments in a loop
I have a column of data comprising blocks of 3 entries. Each block of 3 is unique and I need to add a new column which contains n an incremental value for each of the entries within each block as A,...
- 8 years ago
Hi Cul33
In Power query, I would
- Add an index to the core table
- take a copy of the table.
- group the copied table by the first three columns - adding a MIN aggregation column
- Merge the grouped table back to the original table including the new [offset] column
- create a NEW column that subtracts the offset from the index to generate a number that can be converted to ABC
- remove the interum columns.
Phil_Seamark
8 years agoMicrosoft Employee
HI there, Can you please post a small sample of your data so we can suggest some calculations. A mock up would be fine.
Phil_Seamark
8 years agoMicrosoft Employee
Do you have any other columns in your table that can help split the ties into 1,2 & 3?