Hello Sai Arala,
The actual scenario is to create a TO selecting the product from some batches (we say it as batch).
After which we are coming to know that there is no stock physically in that particular batch (for one product).
So, we need to cancel the TO how much the line items may be and generate a new TO selecting the same batches (for the rest items) and a new batch to the item which doesn't have stock.
Hope this explained will be fine.
Thank you.