Page 1 of 1

Need to calculate cumulative value

Posted: Mon Apr 11, 2016 3:38 am
by satheesh_color
Hi All,

Kindly let me know your thoughts on how to calculate the cumulative value based on the below scenario

A B C Amt
1 1 1 10
1 1 2 10
1 1 3 10
1 1 4 10
1 1 4 10

From the above data i would like to calculate the cumulative as below

A B C Amt
1 1 1 10
1 1 2 20
1 1 3 30
1 1 4 10

kindly let me know your thoughts


Thanks

Posted: Mon Apr 11, 2016 6:55 am
by chulett
:idea: Post your rules / requirements for this calculation in words first rather than make people puzzle it out from your example. Which right now really does need an explanation. :?

If all you are talking about is a running total, then all you need is a stage variable in a transformer. If your last value in the output example needs to be 50 rather than 10 then that's a horse of a different color.

Posted: Mon Apr 11, 2016 6:57 am
by qt_ky
Please describe the logic in words, rather than have us guess at reverse engineering what might be happening with the A B and C columns. What's your rule?

Posted: Mon Apr 11, 2016 6:58 am
by qt_ky
Just as I was typing that, I was thinking Craig you would say the same thing... :lol:

Posted: Mon Apr 11, 2016 7:00 am
by chulett
:wink:

It is a pet peeve of mine, pushing one of my (sadly) many buttons.