Ansicht
Dokumentation

BAPI_LAYMOD_SAVEREPLICA - Distribution of Layout Modules

BAPI_LAYMOD_SAVEREPLICA - Distribution of Layout Modules

CPI1466 during Backup   rdisp/max_wprun_time - Maximum work process run time  
This documentation is copyright by SAP AG.
SAP E-Book

Functionality

You use this method to create new layout modules (shelves) and change or delete and post layout module master data. The data relating to master data table MALG (assignment of materials to layout module) is mapped using this method.

In addition to the layout module, the following data can be transferred to the BAPI:

  • Master data:
    Material number, unit of measure, sort sequence in shelf, shelf section, facing, layout module version, layout module variant, exclusion indicator. Exclusion means the material is not contained in the layout module version, that is to say, is not placed on the shelf.
  • Movement data:
    Maximum shelf quantity, optimum shelf quantity, presentation quantity.

The data of the following structures can be created, changed, deleted and updated:

  • DESCRIPTION
  • VERSION
  • VARIANT
  • MATERIAL

You can use this method to map variants of layout modules to define slight differences to the layout module that only apply to a limited number of stores.

If the structure (e.g. DESCRIPTION or MATERIAL) contains a field for the language key or unit of measure, it always also contains a field of the same name with the suffix _ISO. This allows you to enter either the internal SAP code or the standardized ISO code for the value. For further processing, the system converts ISO codes to SAP codes. The ISO code is only used if the SAP code is not transferred. If you use ISO

codes, an ISO code must be uniquely assigned to the SAP codes in Customizing for the units of measure and language key.

Transferred data is posted synchronously, that is to say, an update task is not used. This is necessary because this method is also used in ALE distribution and ALE inbound processing cannot support asynchronous updating, because it does not allow the processing status of the assigned IDocs to be set reliably.

So that it is possible to identify whether a data record is to be processed, the field FUNCTION must contain the following values in the relevant structure:

  • 003,,Delete: Message contains objects that are to be deleted
  • 004,,Change: Message contains changes
  • 005,,Replace: This message replaces previous messages
  • 009,,Original: First message relating to the operation
  • 023,,Wait/compare: Data should not be imported
  • 018,,Resend

If a serious database error occurs during synchronous updating of the application data, a rollback is triggered in the method for all database changes made up to then. If the method is called together with other methods in a commit unit, the database changes for all previous method calls are also rolled back if these were not committed. The rollback is necessary to ensure that database data is consistent, because some application data was updated correctly and some was not.              

Example

Notes

If this method is not used for the ALE distribution of layout modules, the field CHANGE must contain the following values in the relevant structure:

  • 0,,,,Delete a data record
  • 1,,,,Create a data record
  • 2,,,,Change a data record

If field CHANGE does not contain any data, the same material is created as a new data record with a different logical key (e.g. different placement in shelf). A logical, sequence number is assigned to each new material. If the same material is created with the same logical key, the material record is modified if attributes such as facing or front have changed. If a material is to be deleted, it is removed from the layout module and, if applicable, from the variant.

Before a new layout module variant is created, the relevant material record must exist with this variant. If a version of a layout module is deleted, all variants of this version, and all material records for this version (dependent on the variant) are also deleted.

Versions of a layout module are always created with an infinite validity period, and are thus valid for all stores. As soon as a version with a new 'Valid-from' date is posted, the 'Valid-to' date of the earlier version is adjusted accordingly.

If a material is to be removed from an existing layout module (shelf), the field EXCLUSION must be selected in structure MATERIAL. It is only possible to exclude a material if the material exists in the shelf, that is to say, a material record exists with the relevant version.

Every time the method is called, all buffers are deleted.

You can use the TestRun parameter to activate/deactivate updating of data.

The test run parameter can contain the following values

  • ' ' (no value)
    This means that data is updated. This is the standard setting, and is what would normally be expected if the method is called.
  • 'X'
    This value means that this BAPI is only called in simulation mode and that no data is updated.

Further information





Parameters

DESCRIPTIONS
ITEMS
LAYOUT_MODULE
RETURN
TESTRUN
VARIANTS
VERSIONS

Exceptions

Function Group

WLAY_BAPI

General Data in Customer Master   General Data in Customer Master  
This documentation is copyright by SAP AG.

Length: 6631 Date: 20240523 Time: 153100     sap01-206 ( 121 ms )