Wednesday, January 22, 2014

Pricing: add subtotals fields


You want to download OSS note
155012. This explains the steps to add subtotal fields;
however, you will not be adding the option in the subtotal
drop-down box.
In a nutshell, the process is as follows:
Add your field to the following tables:
VBAP, VBRP, KOMP and KOMPAX. (VBRP if you are using field in SIS
Reporting on billing). The value will be transported from
KOMPAX to VBAP and from VBAP to VBRP via standard move
corresponding.

Create a new VOFM Condition value formula. This formula will set
the value of KOMP-ZZFIELD. The value is moved from KOMP to
KOMPAX via move corresponding internally by SAP (this is how the
regular subtotal fields make it to VBAP.

Add code in USEREXIT_XKOMV_BEWERTEN_INIT (RV61AFZB) to clear the
subtotal value at the beginning of pricing. Note, if you wish
to have the subtotal accumulate (like putting subtotal 3 on two
different lines), then you need to do that accumulating in your
VOFM code.

The note is very clear and I have used it to add multiple
subtotals to a document.

No comments:

Post a Comment