Showing results for 
Search instead for 
Did you mean: 

Automatic batch and lowest shelf life should come in GI

0 Kudos


We have some material which are manage with shelf life , so while making the GR user enter the batch number and shelf life of the material now while issuing the material against order or for movt. 21 etc. user have to select the batch number from the system, we required that the lowet batch for which the remaning shlef life is less should come in the GI automatically how to do this.



Accepted Solutions (0)

Answers (3)

Answers (3)

0 Kudos


Former Member
0 Kudos


Create Characteristic for Self Life Expiry Date,Table Name: MCH1, Filed Name- VFDAT & Class Type-023 & after maintain in the material master classifiaction view. in plantdata/storage1 you will give Min. Rem. Self Life days and Total Self Life days, Expiry date will come automatically at the time of G/R, Production date is mandatory.

ex: Here you have to create normal Purchase Order for Batch Material.

Here in my Purchase Order, I took 80 Qty, but when we will receive this material then we have to distribute this qty to 20,20,20,20.

Because Vendor is Supplying this in a Bag and 1 bag = 20 ea.

Means I have to receive 4 bags.

in gr: Here you can see I am splitting 80 qty to 4 line item, means we can get 4 batches from 1 P.O.

when u post gr in breakup qty you can see batch numbers are generated, which are 0000000424, 0000000425, 0000000426, and 0000000427 & And here also you can see SLED/BBD Date .Here you can see the Expiry Date:-

0000000424: 29.07.2011

0000000425: 19.07.2011

0000000426: 02.08.2011

0000000427: 31.07.2011

Create Class: - CL01

Create Sort Rule: - CU70.

Here we have to assign LOBM_RLZ Characteristic in Search Class because based on the remaining days we have to issue.

Here I am assigning Remaining Days, Expiry date, Delivery Date.

And save.

Now I have to create Sort Rule for issuing,

Here you have to give Characteristic and your sorting rule, what rule you want to use FIFO or LIFO,

If FIFO then Select Ascending

If LIFO then Descending.

And Save.

Here you can see I am issuing 30 ea and Batch number is not there, for adopting a batch number you have to click on stock determination on all

here you can see I am issuing 30 ea and Batch number is not there, for adopting a batch number you have to click on stock determination on all

click on strategy information And put your Sort Rule like ZSORT and click on copy after click on selection Criteria & save (yes)

Now here you can see your batch number is coming automatically based on Remaining Expiry Days

Click on copy, Here we can see qty is distributed based on the batch Qty,Check and Post.



Active Contributor
0 Kudos

Hi Zafar,

You can do this with defining and configuring the batch search strategy in IMG...follow the path and check out

IMG>> Logistic General >> Batch Management >>Batch Determination and Batch Check

>> Condition Tables (use the existing or create your own if you have auths)

>> Access Sequence

>> Strategy Types (select as per your requirement [Inventory or Sales etc])

>> Search Procedure

Before this you have to define the class with type 23 and define/create your sort rule which uses FIFO method to pick the batches with least shelf life.