Page 1 of 1
Increment 1 Digit After Certain Number of Records
Posted: Wed Oct 09, 2013 12:43 am
by pranabdas
We have to develop one mapping for a field as - "Initialise to 3000. Increase by 1 for every 5000 records."
Please suggest how to develop this. Thanks.
Posted: Wed Oct 09, 2013 12:51 am
by chulett
Stage variables in a transformer is the first thing that comes to mind. Or the use of the MOD() function. Of course, running this on multiple nodes could complicate the solution, depending on how that needed to be handled.
Posted: Wed Oct 09, 2013 4:32 am
by ray.wurlod
Integer stage variable svExample initialised to 3000.
Derive stage variable svExample as
Code: Select all
svExample + Not(Mod(@INROWNUM,5000))
Execute Transformer stage in sequential mode.