Replace numbers variable in a column

Hi there,

I have a table with date and time stamp columns as string or integer values. The integer date values occur multipal times but chronologically, see screenshot.
image

Now I want to replace the values in “shift” column using a counter starting with 1 and Count 1 up until the “shift date” value i not the same as in the previous row. In this case the “Replace Counter” have to start at 1 again.
If this helps, I can change the data type of the “shift” column to Integer or Long.

Brotfahrer

Hello @Brotfahrer,

seems to me you are looking for Rank node. Define shift date as grouping attribute and shift as ranking attribute with Ascending order.

Alternatively you could use Counter Generation node within group loop (see Group Loop Start node).

Br,
Ivan

1 Like

Hella @ipazin,

the Rank Node do exactly what I want. Perfect!

Greetings
Brotfahrer

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.