Ansicht
Dokumentation

JYMDISJ2 - IS-M/MDIS: Enhanced Statistics Update for Corr.Orders

JYMDISJ2 - IS-M/MDIS: Enhanced Statistics Update for Corr.Orders

PERFORM Short Reference   BAL Application Log Documentation  
This documentation is copyright by SAP AG.
SAP E-Book

Data from the sales documents together with some enriched data from the standard system are used for the statistics update from the correction requests in Media Sales and Distribution.

If you want to use additional data for the statistics update that is not provided as standard, this data can be obtained by means of the following user exits:

  • User exit '110' - Data enrichment at document header level
  • User exit '111' - Data enrichment at item level
  • User exit '112' - 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, MCJKAKUSR (document header level), MCJKAPUSR (item level) and MCJKEPUSR (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 '110':
  • I_XMCJKAK (all fields from document header - structure MCJKAKB)

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

  • T_XJFFA (internal table containing document flow data; contains reference to sales order)

User exit '111':
  • I_XMCJKAK (all fields from document header - structure MCJKAKB)

  • I_XMCJKAP (all fields from document item - structure MCJKAPB)

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

  • T_XJFFA (internal table of document flow data; contains reference to sales order)

  • T_XJKPA (internal table of partner data, old status)

  • T_YJKPA (internal table of partner data, new status)

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

  • I_XMCJKAP (all fields from document item - structure MCJKAPB)

  • I_XMCJKEP (all fields from document schedule line - structure MCJKEPB)

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

  • T_XJFFA (internal table of document flow data; contains reference to sales order)

  • T_XJKPA (internal table of partner data, old status)

  • T_YJKPA (internal table of partner data, new status)

This means data from the document header and the document item are also offered in schedule line processing. If a document 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 user structures E_XMCJKAKUSR (user exit '110'), E_XMCJKAPUSR (user exit '111') and E_XMCJKEPUSR (user exit '112').
  1. Field catalogs
The new fields must be included in field catalogs so that they can be used in defining info structures.
CAUTION
The following problem scenarios must be taken into account when using these user exits:
a) Update for document changes
The application always provides two kinds of data for document changes: the document data that corresponds to the version of the document before the change and the document data after the change.
The statistics update resets the statistics data updated originally (negative posting) with the data before the document change. The normal statistics update is performed with the new data.
If you determine additional data using user exits, you must ensure that this data has not been changed since the last document change or that the old versions of the data can also be determined. The processing status of the old versions is indicated by the entry in field SUPKZ. A '1' in the field means that the old document data is currently being processed and a '2' means that the new version of the document is offered.
b) Reading data twice
If additional data is determined from the customer or material master record, you must check if the document data can also be enriched. The master data is read during document processing. If the additional fields required for the statistics update are added to the document data, these can be provided when the master data is read in document processing. User exits are also available for document processing at this point. In this case, determination need not be repeated during the statistics update. The problem of determining 'old' data versions (see above) also no longer applies here since the old field contents are stored in the document.
c) Data in the tables transferred
The tables transferred are available for obtaining information required when enriching the export structures. Changes to internal tables can affect user exits called up afterwards; for this reason, it is not advisable to change the data in the internal tables.





Fill RESBD Structure from EBP Component Structure   TXBHW - Original Tax Base Amount in Local Currency  
This documentation is copyright by SAP AG.

Length: 6786 Date: 20240423 Time: 231400     sap01-206 ( 147 ms )