Hi anyone know how to do a "select distinct" from itab data and do some calculation.
For example:
This is my itab result data:
Col1 | Col2 | Col3 | col4
-
123 |000010 |a | 10.00
123 |000010 |b | 2.00
123 |000010 |c | 3.00
123 |000020 |a | 10.50
123 |000020 |b | 2.50
123 |000020 |c | 3.50
123 |000030 |a | 50.00
123 |000030 |b | 6.00
123 |000030 |c | 7.00
I need to do some calculation of a value a - (b value + c value) = x value and x value update back to value a col where the value of a, b, c must be match of col2.
ideally return 000010: x value = 5.00
000020: x value = 4.50
000030: x value = 37.00
How can I able to differential the data from cols2?
aish.