Show TOC

New Fields For Output Control

Basics of modification in output control

If you also want to use a new field for the setup of condition tables (key field) it must also be included in the structure KOMBZ (contained in KOMB).
The following user exits exist in member RVCOMFZ1:
The following user exits exist in member RVCOMFZZ:
The following user exit exists in member RVCOMFZ4:

In output determination, communication table KOMB contains all key fields that can be used for conditions for output determination.

When you create new fields for output determination, you can distinguishbetween two types of fields:

Both types of field have to be included in KOMKBV1. Fields which are only used to query conditions do not have to be included in KOMB and T681F or in the field catalog.

Note concerning name assignment

There are two possibilities for naming the field:

Example 1: Creating a new key field in output control

If, for example, you want to use the field ERNAM (name of sales employee) from the sales order (table VBAK) for output determination, proceed as follows:

1. Enter the field ZZERNAM in communication structure KOMKBV1 in INCLUDE KOMKBZ3 in the Data Dictionary.
By entering the field in KOMKBZ3, you automatically include it in communication table KOMKBV1.
2. Enter ZZERNAM in the communication table KOMB (in KOMBZ).
3. Assign values to the fields
Values are assigned to the fields in function module KOMKBV1_FILL. You have to enter the field and assign value to it manually in user exit USEREXIT_KOMKBV1_FILL. You will find the statements that you can use as a reference in the user exits.
Copying partner numbers is a special case and will be explained in Example 3.
4. Include ZZERNAM in the field catalog for the condition table for sales documents. The field catalogs must contain all the fields which you want to use to structure condition tables.

Example 2: Entering a condition field in the communication block

If you want to use condition field VBAK-AUDAT for output determination, proceed as described in Example 1. Remember that it is not necessary to include the new field in KOMBZ (KOMB) or to maintain table T681F or the field catalog.

Example 3: Entering a partner number in the communication block

Example 3 presupposes that there is a new partner function for buyer ZY in the sales document and that the number of this partner is to be copied.

When entering partner numbers in the communication block, proceed as described in the examples above. Partner function ZY is assigned to partner type AP in this example.

Remember to use a different routine to assign values to the new fields. If, for example, you want to copy the partner function ZY into the new field ZZEINKA, for example, the statement is:

USEREXIT_KOMKBV1_PARTNER

WHEN'ZY'.COM_KBV1-ZZEINKA = COM_VBPA-PARNR.

The VBPA field used to assign a value to the new field depends on the partner function determined in the sales order. Each partner function is assigned to a partner type (e.g. partner function LF - partner type LI), which controls the assignment. Other source fields should be used for other partner types: COM_VBPA-KUNNR, COM_VBPA-LIFNR, COM_VBPA-PERNR and COM_VBPA-PARNR.

The following assignments exist: