on 06-02-2014 3:36 PM
I have data that looks like this
<Records>
<VBLEN>123</VBLEN>
<MATNR>012356</MATNR>
<ZSPR>1.02</VBLEN>
</Records>
<Records>
<VBLEN>123</VBLEN>
<MATNR>568954</MATNR>
<ZSPR>2.05</ZSPR>
</Records>
<Records>
<VBLEN>856</VBLEN>
<MATNR>259865</MATNR>
<ZSPR>5.98</ZSPR>
</Records>
<Records>
<VBLEN>856</VBLEN>
<MATNR>359874</MATNR>
<ZSPR>4.12</ZPSR>
</Records>
<Records>
<VBLEN>856</VBLEN>
<MATNR>985698</MATNR>
<ZSPR>1.06</ZSPR>
</Records>
In my output, I have a field on every line that is a total. So My output needs to look like this.
<Records>
<VBLEN>123</VBLEN>
<MATNR>012356<MATNR>
<ZSPR_TOTAL>3.07</ZSPR_TOTAL>
</Records>
<Records>
<VBELN>123</VBLEN>
<MATNR>568954</MATNR>
<ZSPR_TOTAL>3.07<ZSPR_TOTAL>
</Records>
<Records>
<VBLEN>856</VBLEN>
<MATNR>259865</MATNR>
<ZSPR_TOTAL>11.16</ZPSR_TOTAL>
</Records>
<VBLEN>856</VBLEN>
<MATNR>359874</MATNR>
<ZSPR_TOTAL>11.16</ZSPR_TOTAL>
</Records>
<Records>
<VBLEN>856</VBLEN>
<MATNR985698</MATNR>
<ZSPR_TOTAL>11.16</ZSPR_TOTAL>
So I need the sum of ZSPR on each line, but it has to be the sum of ZSPR for each instance of VBLEN.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you both for your help
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.