Ansicht
Dokumentation

/AFS/BAPI_MAT_AVAILABILITY - Material Availability Display

/AFS/BAPI_MAT_AVAILABILITY - Material Availability Display

rdisp/max_wprun_time - Maximum work process run time   General Data in Customer Master  
This documentation is copyright by SAP AG.
SAP E-Book

Functionality

You use this BAPI (/AFS/BAPI_MAT_AVAILABILITY) to determine the available quantity for an AFS material in a certain plant according to the ATP logic. The result given by this BAPI is same as the ATP simulation (Transaction J4A{ ).

The availability check is carried out on transferring the material number, the plant and the unit-of-measure (for display). The scope of the check, that is, which stocks, receipts and issues are to be included in the check is defined by the combination of checking group (material master) and checking rule. In the function module, the system uses the default checking rule defined in sales and distribution (A).

You use STOCK_INDICATOR to determine the subcontracting or consignment case. If it is O, VENDOR has to be supplied and if it is W, CUSTOMER has to be supplied.

The results of the check depend on the following entries:

  • If no date is transferred, the system displays the ATP situation from today's date into the future date as the result.
  • If a date is transferred, the system displays the ATP situation from the corresponding date as the result.

The results of the availability check are recorded in two output tables as mentioned below:

  • AFS_ATP_RESULT1: This table contains the result in the same format of transaction J4A{ (ATP simulation).
  • AFS_ATP_RESULT2: This table contains dates and available receipt quantities (ATP quantities) along with stock information.

Both the tables contain dates and available receipt quantities (ATP quantities) along with SKU information.

The system also displays the end of the replenishment lead time (ENDLEADTME) if the check with replenishment lead time is switched ON.

Example

Notes

You can use the BAdI /afs/sd_mod_atp_res methods change_input_atp and change_output_atp to modify the input and output respectively.

AFS requirement category is necessary for an AFS material with category structure. If it is not supplied, then the system will look for default category customization.

When the caller_applciation is V (sales) SALES_ORGANIZATION, DISTRIBUTION_CHANNEL, DIVISION will be used to determine the SKU status, so that only valid SKUs can be sent for ATP check.

Further information





Parameters

AFS_ATP_RESULT1
AFS_ATP_RESULT2
CALLER_APPLICATION
CHECKING_RULE
CUSTOMER
DISTRIBUTION_CHANNEL
DIVISION
DOCUMENT_TYPE
END_LEADTIME
EXTENSIONIN
EXTENSIONOUT
MATERIAL
PLANT
REQUESTED_DATE
REQUIREMENT_CATEGORY
RETURN
SALES_ORGANIZATION
STOCK_INDICATOR
UNIT_OF_MEASURE
VENDOR

Exceptions

Function Group

/SAPLATPB

SUBST_MERGE_LIST - merge external lists to one complete list with #if... logic for R3up   CL_GUI_FRONTEND_SERVICES - Frontend Services  
This documentation is copyright by SAP AG.

Length: 4725 Date: 20240418 Time: 023737     sap01-206 ( 88 ms )