Ansicht
Dokumentation

FKK_ODN_PROC_CC - Change Document Class Determination

FKK_ODN_PROC_CC - Change Document Class Determination

CPI1466 during Backup   TXBHW - Original Tax Base Amount in Local Currency  
This documentation is copyright by SAP AG.
SAP E-Book

Functionality

The database table for official document numbering (DFKKEXTDOC) contains the field DOCCLS. This field controls from which number range the system derives the official document number (ODN) that is to be assigned to the document, or from which external system or application the system derives an external number that is to be assigned to the document as the ODN.

This function module is used to change the standard document class that is determined by the system. Implementing the function module also enables you to use all comparison operators that are not possible in Customizing for ODN, which only supports settings that use specific parameter values.

Copy this function module to your local customer namespace (for example, Z*) and implement the logic according to your requirements.

Example

You want to use different numbering and formatting for invoices whose amount exceeds a particular threshold value.

You have filled the attribute field ATTRIBUTE1 with formatting data and the attribute field ATTRIBUTE2 with a value for a valid document class. For more information, see the documentation of the function module Fill Attribute Fields (FKK_ODN_PROC_AT).

Assign the deviating document class from ATTRIBUTE2 (IS_ATTRSTR-ATTRIBUTE2), which has already been determined and saved, to the export parameter CV_DOCCLS.

Note the following:

  • If none of the attribute fields contain the document class that is to be used, you must implement the logic for setting the export parameter CV_DOCCLS in this function module.
  • If no document class is returned for a document, the corresponding document is not numbered and is processed accordingly.

Notes

External numbers and internal official document numbers used at the same time:

If the standard document class is changed by this function module, the derived document class must not use external numbers.

If it is not possible to differentiate between external numbers and internal official document numbers by using two document classes with different values for document type, origin, and sub-ID, you must enter the document class for external numbering as the standard document class in the Customizing activity Assign Document Classes to Document Types and Origin Keys. The document class derived by this function module must use a number range to generate internal official document numbers.

Further information





Parameters

CV_DOCCLS
IS_ATTRSTR
IS_FKKKO
IS_FKKOP
IT_FKKCL
IT_FKKOP
IT_FKKOPK
IT_FKKOPW
IV_AUGRD
IV_CALLID
IV_CANCEL
IV_LAND
IV_PROCESS
IV_SUBID

Exceptions

Function Group

FKK_ODN_PROCESS

BAL Application Log Documentation   Addresses (Business Address Services)  
This documentation is copyright by SAP AG.

Length: 3171 Date: 20240523 Time: 150503     sap01-206 ( 66 ms )