Enterprise Resource Planning Blogs by SAP
Get insights and updates about cloud ERP and RISE with SAP, SAP S/4HANA and SAP S/4HANA Cloud, and more enterprise management capabilities with SAP blog posts.
Showing results for 
Search instead for 
Did you mean: 


In SAP S/4HANA Cloud system, you can use batch determination in goods movements when you are dealing with a goods issue posting (for instance, a consumption posting to a cost center), with a stock transfer or with a transfer posting.
In this Blog, we will learn the process of setting up batch determination in inventory management.


Set up a sample of batch determination in transfer posting within plant(movement type 311). Our example is as followings:

We need to transfer batch stock for raw material RM_BATCH_SAM from storage location 131A to storage location 131B. During such kind of transfer posting, our purpose is to only transfer batches with PH value higher than 5. Meanwhile, we also want to transfer the raw materials based on “first-in first-out” approach, which means those raw material batches come to warehouse first should be used firstly.


  • Batch management materials need to be created and Purchasing view and General Plant Data / Storage view should be maintained for the materials.

  • Several batches are created and classified for the materials. In our example, the batches  are classified with two characteristics:
    Standard characteristic: Date of Last Goods Receipt (LOBM_LWEDT)
    Custom characteristic: PH

  • Goods receipt has been done to the batches in sourcing storage location to make sure they have stock to do batch determination.

In our scenario, there are 4 available batches in the example plant and storage location.

Batch PH Last Goods Receipt Date Available Qty
131A_1 6 21.11.2022 100
302 7 01.02.2023 20
303 5 01.02.2023 50
307 6 31.01.2023 30

Configuration Steps

  1. Create selection class in App: Manage Classes (ID: CL02). The selection class should be part of the batch class for raw materials in material master, but some of the standard characteristics may not need to be entered in the batch class but only need to be entered in the selection class. For example, LOBM_RLZ and LOBM_LFDAT.

  2. Create Sorting rule in App: Create Sort Sequence (ID: CU70). The characteristics in the sorting rule should be part of the batch class for raw materials in the material master.

  3. Define condition tables to determine batches for Inventory Management in configuration step: 103950 or 103951. A condition table defines the combination of fields that specifies the validity of an individual condition record. And it will be used in our next step to define access sequence.
    In our scenario, we could use the standard predefined condition table: 024. It is the combination of Movement Type/Plant/Material

  4. Define Inventory Management access sequences in configure step: 102169. Access sequence defines an access sequence according to which the system uses to first find a search strategy using condition table. And it will be used in our next step to define strategy type.
    In our scenario, we could use the standard access sequence: ME01. It contains 5 condition tables: 024, 023, 022, 021, 020

  5. Define Inventory Management Strategy Types in configuration step: 102146. Strategy type defines one search strategy by linking selection class(Step 1) and sorting rule(Step 2) to access sequence(Step 4).
    In our scenario, we created a new strategy type: Z001 to set up such a link.

  6. Define Inventory Management Search Procedure in configuration step: 102147. A batch search procedure comprises all strategy types that can be used for a particular combination of plant and order type.
    In our scenario, we created a new search procedure Z00001 which contains strategy type Z001:

  7. Allocate IM Search Procedure and Activate Check to specific movement type in configuration step 102148.
    In our scenario, we will assign the search procedure Z00001 to movement type 311.

  8. Build Search Strategies for Inventory Management in App: Manage Search Strategies - Inventory Management(ID: MBC2)
    To make sure all transfer batches’ PH value is higher than 5. We define characteristic PH> 5 in the Search strategy.


  1. Test in app: Post Goods Movement(MIGO) for transfer posting 311. Enter plant: 1310, From. storage location: 131A, Dest. storage location 131B and Qty in UnE 10. Then click on button "Stock Determ." to trigger batch determination.

  2. According to our search criteria: PH > 5 and sorting rule: Ascending by Last Goods Receipt Date, batch 131A_1 should be determined here. You may check the batch determination log for more details.

    Here you could see that batch 303 is excluded according to selection criteria because its PH value is 5 which cannot fit our selection criteria PH > 5. All other 3 batches meet the selection criteria and are sorted by the sorting rule: Ascending by Last Goods Receipt Date. So batch 131A_1 is determined in our scenario.

In closing

I hope this blog has helped you understand the basic steps to set up Batch Determination in Inventory Management in SAP S/4HANA Cloud. Although we only show an example for transfer posting movement type 311, the similar set-up steps could also fit other goods issue movement.  Please feel free to share your feedback and thoughts in a comment. And I will update more blogs of batch management in SAP S/4HANA Cloud.

1 Comment