on 08-08-2007 8:17 AM
Hi,
I have a message with the following structure.
Plant, Storage Location, matnr, qty.
I want to sum the quantity by comparing the key fields in XI. how can I do it?
say for example if I have the follwoing values,
PLNT1 STO1 Mat1 20
PLNT1 STO1 Mat1 40
PLNT1 STO1 Mat2 20
The result shud look like this
PLNT1 STO1 Mat1 60
PLNT1 STO1 Mat2 20.
How can I do this?
with regards,
Vamsi
Hi,
Use standard functions count and sum in mapping.
Regards,
S.RamNarender
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
From My point of View, I will suggest to write the UDF with 4 as input parameters and 1 as output paramter. I will give the logic as follows
1 Take your key fields and quantity as input parameters
2. Take all values as queue based so that you will have all values in hand
3. Write the logic in JAVA by comparing the values and do the sum and reteturn with summation values
4. return the values you got in resultlist.
I hope it is clear for you.
Warm Regards,
Vijay
User | Count |
---|---|
71 | |
26 | |
10 | |
9 | |
7 | |
6 | |
4 | |
4 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.