Ansicht
Dokumentation

ALGEX004 - Enhancement for external Assignment IP to Material

ALGEX004 - Enhancement for external Assignment IP to Material

TXBHW - Original Tax Base Amount in Local Currency   Addresses (Business Address Services)  
This documentation is copyright by SAP AG.
SAP E-Book

General Description

The Customer Exit EXIT_SAPLORF3_004 (function module of function group XORF7) allows to implement an user defined assignment of the IP part type to the material. This can be explained as follows:

During an IP session, the user can create material master records. Thereby, the created material number is defined by the IP customizing (Reference-> TQ Cust.).

One possibilty to identify the material master records is given by the relation:

MARA-MFRPN (MM: MPN) = SPCIPPDR-PNR (IP: Part Number),

MARA-MFRNR (MM: external Manufacturer) = SPCIPPDR-MFR (IP: Manufacturer).

Hence, the material records can be found from the IP data during the stock calculation. This is done by the fucntion module ASSIGN_MATNR2 (function group ORF3). Therefore, the customizing flag for the assignment of the IP part type to the material (Reference -> IRFC1/2) has to be set to 'MPN=PNR (IP), Manufacturer=MFR'.

If the user assign the material master records in an other manner by creating master records from the IP transactions, the user has to implement this customer exit to find the material records from the IP data during the stock calculation. Therefore, the customizing flag for the assignment of the IP part type to the material (Reference -> IRFC1/2) has to be set to 'User defined by User Exit'.

Interface

The most important interface (import and export) of this Customer Exit is given by the structure WA_PARTS. This structure is defined in the Data Dictionary like ORFPART. This structure describes the data after selecting it from the databases and before it is converted and written to the screen 0200 of program ORF2. The structur refers to one part type. The structure contains the IP data. It also contains empty fields for the material data, the data of the MTBE extractor as well as the fields for an extractor, which can be implemented by the Customer Exit EXIT_SAPLORF3_005.

Besides the structure WA_PARTS , the user has access to the IP tables I_SPCIPHDR, I_SPCIPPDR, I_SPCIPPDS and I_SPCIPCSN. This internal tables are defined like the Data Dictionary database tables SPCIPHDR, SPCIPPDR, SPCIPPDS and SPCIPCSN. They contain all parts, that are selected in the IP database on the first screen of the transaction. An change on the internal tables will not initiate an IP database change. An other table, I_PARTS, describes the marked parts in the IP transaction. The internal table IT_SPCIPIF describes a copy of the customizing table SPCIPINTERFACE of the IP transaction (Reference->IP Cust), which describes the assignment of IP to material data by the creation of material master records. The internal table IT_MMOUT2 contains all material master records, which have a MFRPN and MFRNR that is not initial. The latter two tables are read from the database in the function module ASSIGN_MATNR (function group ORF3).

As the result of this Customer Exit, the assigned material number has to be written to the to the export parameter WA_MMIN-MATNR.

Structure of the Coding

The function module EXIT_SAPLORF3_004 is called from the function module FILL_IT_PARTS (function group: ORF3) which is used in the program ORF2 (Single Item Stock Calculation) and ORF6 (Multible Item Stock Calculation). Hence, the function module is called for every IP part type seperately.

Example Use

The extractor should determine the assigned material number in dependence on the IP part data. This material number has to be written to the export parameter WA_MMIN-MATNR.

As explanation, please compare the call of the function module ASSIGN_MATNR2, which is also located in the function module FILL_IT_PARTS, with the call of this Customer Exit. The function module ASSIGN_MATNR2 provides the material number in the case of internal material assignment 'MPN=PNR (IP), Manufacturer=MFR' (see above).






rdisp/max_wprun_time - Maximum work process run time   CL_GUI_FRONTEND_SERVICES - Frontend Services  
This documentation is copyright by SAP AG.

Length: 4119 Date: 20240328 Time: 175239     sap01-206 ( 115 ms )