Learnerwithnolimit
Learnerwithnolimit

Reputation: 1

Power Query Custom Column

I need help with Power Query Custom Column.

I would like to have the num_ech as you can see in the picture below which will be dynamically incremented by + 1 according to the id which also changes. As the data will continue growing I'd to create it in Power Query Custom Column. enter image description here

Upvotes: 0

Views: 137

Answers (1)

horseyride
horseyride

Reputation: 21298

right click the id column and group by. accept all defaults and hit ok

in code window (or home ... advanced editor) change code from something that looks like this

= Table.Group(#"Changed Type", {"id"}, {{"Count", each Table.RowCount(_), type number}})

to this

= Table.Group(#"Changed Type", {"id"}, {{"data", each Table.AddIndexColumn(_, "num_ech", 0, 1), type table}})

then use arrows atop the column to [x] expand everything except id

Upvotes: 1

Related Questions