Fonction SAP BAPI_PLANNEDORDER_CHANGE - Change planned order

Paramètre Reférence Type Long. Valeur par déf. Facultatif Description
HEADERDATA BAPIPLAF_I2 u 130 Header data (from external system)
HEADERDATAX BAPIPLAF_I2X u 23 Change header data indicator fields
PLANNEDORDER BAPI_PLDORD-PLDORD_NUM C 10 Planned order number

Paramètre Reférence Type Long. Description
CAPACITYHEADERDATA1 BAPI_KBKO u 83 Capacity header data (detailed scheduling)
CAPACITYHEADERDATA2 BAPI_KBKO u 83 Capacity header data (rate-based scheduling)
CAPACITYHEADERDATA3 BAPI_KBKO u 83 Capacity header data (rough-cut scheduling)
CHANGEDHEADERDATA BAPIPLAF_E1 u 747 Header Data (from SAP for External System)
RETURN BAPIRETURN1 u 470 Confirmations

Paramètre Reférence Long. Facultatif Description
CAPACITYDATA1 BAPI_PLDORDCAPA_E1 103 X Capacity data (detailed scheduling)
CAPACITYDATA2 BAPI_PLDORDCAPA_E1 103 X Capacity data (rate-based scheduling)
CAPACITYDATA3 BAPI_PLDORDCAPA_E1 103 X Capacity data (rough-cut scheduling)
COMPONENTSDATA BAPI_PLDORDCOMP_E1 300 X Material component data

Functionality
This method can be used to change the header data of a planned order.
For example, you can change the order quantity of a planned order. Usingthis method, changing the values in the header data always will triggerrescheduling and re-explosion of the Bill of Material for the plannedorder.
To help you understand how the method can be used, test transaction"MDBA" is available. It has integrated all 6 planned order methods intoa transaction to deal with planned orders. For more information, pleaserefer to the program documentation on this transaction. The name of theprogram is "MDBAPI01".

Restriction:
Please note that this method can not be used to change the materialcomponents of a planned order.

Example

Notes

Authorization checks:
The following authorization objects are checked with the activity V(change):

  • M_PLAF_ORG

  • M_LFPL_ORG
  • Parameter interdependencies:
    Parameter "HEADERDATA" and "HEADERDATAX have the followinginterdependencies:
    "HEADERDATA" is used to enter the values to change a planned order, andthe corresponding fields in "HEADERDATAX" must be filled if you want tomake the entry in "HEADERDATA" valid. The two parameters consist of thesame fields with the same names.

    Further methods:

    • CommitWork

    • RollbackWork

    • If you have decided that the changes made by this method are to be savedin the database, you have to call up the methodCommitWork. If you decide not to savethe data to the database, you can call the methodRollbackWork instead.
      You can find more information in the parameter documentation of theparameters below.

      Confirmations:
      Messages are received back in the parameter 'Return'. You can findreturn values and their meaning in this parameter documentation.

      Further information

      Description
      When a planned order has been successfully changed by the method, thecapacitiy header data of the planned order will be exported via thisparameter if detailed scheduling data exists.
      You can find information on the meaning of individual parameter fieldsin the corresponding data element documentation in the ABAP Dictionary.

      Description
      When a planned order has been successfully changed by the method, thecapacitiy header data of the planned order will be exported via thisparameter if rate-based scheduling data exists.
      You can find information on the meaning of individual parameter fieldsin the corresponding data element documentation in the ABAP Dictionary.

      Description
      When a planned order has been successfully changed by the method, thecapacitiy header data of the planned order will be exported via thisparameter if rate-based scheduling data exists.
      You can find information on the meaning of individual parameter fieldsin the corresponding data element documentation in the ABAP Dictionary.

      Description
      If the planned order changes were carried out successfully regardingmethod, this structure will have the compelete record of the headerdata for the changed planned order. Using this data, you can decidewhether changes should actually be made or not.
      INCLUDE BAPI_DATAELEMENT

      Description
      INCLUDE BAPI_TABLE

      Value range

      Error messages

      Type ID Number Message
      E MD 651 No imported data has been setwith the flag for "change"
      E MD 652 Planned order number has notbeen entered
      E 61 003 Planned order & does notexist
      E 61 400 No authorization for & in plant and mrp controller
      E MD 130 You do not have thenecess.authorization for this function (see long txt)
      E MD 653 Not possible to changecomponent firming indicator with reqmts totaling

      Warning messages

      Type ID Number Message
      I 61 768 The system could not determinea storage location
      I 61 027 No material components weredetermined

      Success messages

      Type ID Number Message
      S 61 011 Planned order & will be changed
      Please note that other messages also exist which may appear if an erroroccurs when executing the method.
      To receive the details of a backflush, you can use the method,Message.GetDetail.

      Description
      This is an important parameter in the form of a structure. Theparameters in this structure are the parameters that can be changedusing this method.

      Important note:
      This parameter must be used in correspondance with another parameter"HEADERDATAX". For each field in this structure filled with a new valueto change the planned order with, you must set value 'X' in thecorresponding field in "HEADERDATAX". For example, if you want tochange the total quantity of a planned order, you enter the desiredvalue in HEADERDATAX-TOTAL_QTY with an 'X'.
      You can find information on the meaning of individual parameter fieldsin the corresponding data element documentation in the ABAP Dictionary.

      Description
      This parameter consists of check fields. There is a check field forevery field that is included in the parameter "HEADERDATA" with thesame field name. If you give value 'X' to the fields in this parameter,the system assumes that the corresponding field in the parameter"HEADERDATA" is meant to be used to change the planned order with. Thismeans that even if you fill a field in the parameter "HEADERDATA"aiming to make a change to a planned order with the value, the systemignores the changes unless you set a flag in this parameter.

      Description
      You can find information on the meaning of the planned order number inthe data element documentation:
      planned order number
      INCLUDE BAPI_KEYFIELD

      Description
      When a planned order has been successfully changed by the method, thecapacity data of the planned order will be exported via this parameterif detailed scheduling data exists.
      You can find information on the meaning of individual parameter fieldsin the corresponding data element documentation in the ABAP Dictionary.

      Description
      When a planned order has been successfully changed by the method, thecapacity data of the planned order will be exported via this parameterif rate-based scheduling data exists.
      You can find information on the meaning of individual parameter fieldsin the corresponding data element documentation in the ABAP Dictionary.

      Description
      When a planned order has been successfully changed by the method, thecapacity data of the planned order will be exported via this parameterif rough-cut scheduling data exists.
      You can find information on the meaning of individual parameter fieldsin the corresponding data element documentation in the ABAP Dictionary.

      Description
      If a planned order has been successfully changed by the method and hasmaterial components, all material components data will be exported withthis parameter.

      Note:
      This parameter is only used as an EXPORT parameter. It is not used tochange the material components of a planned order.
      You can find information on the meaning of individual parameter fieldsin the corresponding data element documentation in the ABAP Dictionary.

1508714Fixing ind. not reset via BAPI_PLANNEDORDER_CHANGE for AFS
1484403Error 8J 843 during AFS planned order change via BAPI
1466837Error 82 807 during plnd ord. creation for AFS matl via BAPI
1471616Incorrect SKU / markers created via BAPI_PLANNEDORDER_CREATE
1075141BAPIs valid for usage with AFS6.0
1135411Header, component SKU and marker information not saved
1101029Issues with AFS BAPI for planned order create and change
1046750Update Termination when changing Planned order via BAPI
641489R/3->APO: Unchanged planned orders sent to APO (BAPI)
400255Mistranslation of JA text for Data Element PLAFX