If your inventory model is Standard cost and you still want to have the on-hand reservation by FIFO, oldest batch number first, you can change the logic a little bit to get this ability
Because of the oldest batch so it also means the oldest inventdim. So the trick is to get the oldest inventDim Id