Quantcast
Channel: Pentaho Community Forums
Viewing all articles
Browse latest Browse all 16689

Row_number Over inside a transformation

$
0
0
Hi.

I have to create transformation and I need to create a sequence number that will get reset after x amount of rows. On SQL I would use a row_number() over (partition by... order by) function, but not sure how to create this on pentaho?

Ex:
Source data
login -- role -- sequence (row number) that i need to generate
1 -- a -- 1
1 -- b -- 2
2 -- c -- 1
2 -- r -- 2
2 -- a -- 3
3 -- a -- 1
4 -- a -- 1
4 -- b -- 2
5 -- a -- 1

I have tried the "group by" step but it doesn't have an option to reset the count

Any help will be appreciated.

Christiam

Viewing all articles
Browse latest Browse all 16689

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>