column where the data may be the same in several rows. For each occurance I would like to append a suffix.

Hi newer user. I have a column where the data may be the same in several rows. For each occurance I would like to append a suffix.
|Before |After|
|
A A1
B B1
C C1
A A2
B B2
B B3
C C2
D D1

Take a look at Rank — NodePit

1 Like

Hello @Ricks123,

before Rank node you can use Counter Generation node to have column based on which you can do ascending order as your first column from example is grouping attribute. Follow it up with String Manipulation node using join() function to join original column and rank.

Hope this helps and welcome to KNIME Community!

Br,
Ivan

Ivan thx for the response. I need to count each occurance because I need to be able to get for example B3 (see above) specifically. I will not know where that would be in rank from file to file.

Hello @Ricks123,

seems like you could use an example workflow:
2021_02_01_RankExample.knwf (13.9 KB)

If this is related to another topic (Split a table using a row that may not always be in same place) maybe this helps as well in case you always need everything below B3. As said there it will be dynamic and should work same for different files.

Br,
Ivan

Yes , it is related. The problem is that I will not know the rank number, it could be different in each file.

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