Skip to Content
0
Jul 30, 2023 at 10:31 AM

Batch in row already exists in InventoryGenEntries via SAP B1 Service Layer

114 Views Last edit Jul 29, 2023 at 08:05 AM 3 rev

Hi Team,

I am using the Service Layer to create Goods Receipt transaction (via InventoryGenEntries entity). Please find the request url and body below.

https://192.168.100.100:50000/b1s/v1/InventoryGenEntries
{
"DocDate": "20230729",
"DocCur": "INR",
"DocRate": 1,
"Series": 0,
"BPLId": 1,
"BPL_IDAssignedToInvoice": 1,
"DocumentLines": [
{
"ItemCode": "ITEM001",
"Quantity": 48,
"Currency": "INR",
"Rate": 1,
"WarehouseCode": "WH1",
"LineNum": 0,
"BatchNumbers": [
{
"BatchNumber": "101",
"Quantity": 48
}
]
}
]
}

I am getting the below response that the batch already exists in the row, how to add the quantity to the existing batch?

{ "error": { "code": -10, "message": { "lang": "en-us", "value": "10001226 - Batch 101 in row ITEM001 already exists" } }}

Any help will be appreciated