Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi
I have excel files with example like below:
Time | Type | Amount | Balance |
10:01 | D | 100 | 100 |
10:02 | D | 50 | 150 |
10:03 | C | 100 | 50 |
I need to identify the negative (D) amounts in able to create correct Running Balance in my application.
My idea is to create a new column to create a running balance the will show me the running balance so i can identify the correct MAX and MIN.
Time | Type | Amount | New Amount | Balance |
10:01 | D | 100 | -100 | -100 |
10:02 | D | 50 | -50 | -150 |
10:03 | C | 100 | 100 | 50 |
Just create a flag within the load with something:
if(Type = 'D', -1, 1) as Flag
and then you could multiply with it in the expresions, for example:
sum(Amount * Flag) // within the Balance expression
- Marcus
Just create a flag within the load with something:
if(Type = 'D', -1, 1) as Flag
and then you could multiply with it in the expresions, for example:
sum(Amount * Flag) // within the Balance expression
- Marcus