Ansicht
Dokumentation

JYMDISJ4 - IS-M/MDIS: Enhanced Statistics Update for Billing Documents

JYMDISJ4 - IS-M/MDIS: Enhanced Statistics Update for Billing Documents

TXBHW - Original Tax Base Amount in Local Currency   CL_GUI_FRONTEND_SERVICES - Frontend Services  
This documentation is copyright by SAP AG.
SAP E-Book

Data from the documents themselves along with some enriched data from the standard system are used in the statistics update from the billing documents from Media Sales and Distribution.

If you want to use data that is not available as standard for the statistics update, this data can be determined by means of user exits.

  • User exit '100' - Data enrichment at billing document header level
  • User exit '101' - Data enrichment at item level
  • User exit '102' - Data enrichment at schedule line level

Procedure

  1. Define the new data as fields in the ABAP/4 Data Dictionary
The fields must be included in the user structures provided for this purpose, MCJVBKUSR (billing document header level), MCJVBPUSR (item level) and MCJVBEUSR (schedule line level).
  1. Determine the new fields in the user exits
Data from the documents is provided for use in determining the field contents:
User exit '100':
  • I_XMCJVBK (all fields from the billing doc.header - structure MCJVBKB)

  • I_CONTROL (general update control, e.g. normal update or recompilation)

User exit '101':
  • I_XMCJVBK (all fields from billing document header - structure MCJVBKB)

  • I_XMCJVBP (all fields from billing document item - structure MCJVBPB)

  • I_CONTROL (general update control, e.g. normal update or recompilation)

This means data from the billing document header is also offered in item processing. If the billing document contains several items, the user exit is repeated for each item. No data is available from other items when processing an item.
User exit '102':
  • I_XMCJVBK (all fields from billing document header - structure MCJVBKB)

  • I_XMCJVBP (all fields from billing document item - structure MCJVBPB)

  • I_XMCJVBE (all fields from billing doc.sch.line - structure MCJVBEB)

  • I_CONTROL (general update control, e.g. normal update or recompilation)

This means data from the billing document header and item are also provided in schedule line processing. If an item contains several schedule lines, the user exit is repeated for each schedule line. No data from other schedule lines is available when processing a schedule line.
Once the new field contents have been determined, they are passed on to the update program by means of the interface structures provided for this purpose, E_XMCJVBKUSR (user exit '001'), E_XMCJVBPUSR (user exit '002') and E_XMCJVBEUSR (user exit '003').
  1. Field catalogs
The new fields must be added to the field catalogs so that they can be used in defining info structures.
CAUTION
The following problem situations must be taken into account when using these user exits:
a) Updating for billing document changes
The application provides two types of data for billing document changes: the data that corresponds to the version before the billing document change and that after the change.
The statistics update uses the data before the change to cancel the statistics data previously updated (negative posting). The new data is then used to carry out the normal statistics update.
If user exits are used to determine additional data, you must ensure that this data has not been changed since the last billing document change or that the old version of the data can be determined. The processing status of the old versions can be identified from the entry in field SUPKZ. The entry '1' means the old data is currently being processed and '2' means that the new billing document version is offered.
b) Reading data twice
If additional data is determined from the customer or material master record, you must check if it is also possible to enrich the document data. The master data is read during document processing. If the additional fields required for the statistics update are added to the document data, these fields can be made available when the master data is read in document processing. User exits are also available at this point for document processing. This means it is no longer necessary to repeat determination during the statistics update. The problem of determining 'old' data versions (see above) also does not apply here, since the old field contents are already recorded in the document.





ABAP Short Reference   SUBST_MERGE_LIST - merge external lists to one complete list with #if... logic for R3up  
This documentation is copyright by SAP AG.

Length: 5565 Date: 20240427 Time: 050252     sap01-206 ( 84 ms )