ZConsulto Academy

“Cannot add row without complete selection of batch/serial numbers” in SAP Business One®: what to check

Last checked: 5 November 2026, against SAP’s help for SAP Business One 10.0, the SDK help and the Service Layer reference. We have not tested these steps on our own system, so try them on a test company first. SAP’s help doesn’t quote this message, so the link between a cause and the message comes from users and partners unless we say otherwise.

You choose Add, or an import or integration posts a document, and SAP Business One refuses it:

Cannot add row without complete selection of batch/serial numbers

Where you see itWhat it looks like
Desktop clientThe text above. Some older reports add the row: “Cannot add row 3 without complete selection of batch/serial numbers”. We found no recent report from a 10.0 desktop client, so the wording there may differ.
DI API“DI Error: (-4014) Cannot add row without complete selection of batch/serial numbers”
Service LayerJSON with “code”: -4014 and the same text
Data Transfer Workbench (DTW)“1 Created Failed”, then the text, often twice, with 65171 stuck to the end. SAP shows 65171 after another DTW error too, so we read it as a general DTW suffix.

We found no SAP message number for this text.

It means the row’s item is managed by batches or serial numbers, and SAP Business One doesn’t have numbers for the row’s whole quantity. SAP’s help states the rule without naming the message: select less than the row needs and the document can’t be added.

Of the 12 SAP Community posts we found from 2022 onward, most come from imports and integrations, and none is a plain desktop-client case. That’s a small sample, and forum users lean technical. Go to the section that matches where you see it.

1. In the desktop client: finish the selection

For a batch item on an issue document (for example a delivery, A/R invoice, goods issue or inventory transfer):

  1. Open Batch Number Selection. It opens when you choose Add. To open it earlier, press Ctrl+Tab in the row’s Quantity field, or right-click Quantity and choose Batch/Serial Numbers.
  2. In Rows from Documents, select the row and read Whse Code, Total Needed and Total Selected. Total Needed is what’s still to select.
  3. In Available Batches, select a batch and move it to Selected Batches with the arrow button, or choose Auto Select to fill what remains. Auto Select shows when the warehouse has no bin locations or the item is issued primarily by batch numbers.
  4. Choose Update, then OK, then Add on the document.

Serial items use Serial Number Selection, with Available Serial Numbers, Selected Serial Numbers, Auto Select and Open Quantity. Select fewer than Open Quantity and the document can’t be added.

SAP’s page: Batch Number Selection Window.

2. When you can’t complete the selection

  • Not enough in the row’s warehouse. The window works per row and shows that row’s warehouse. If the available batches there can’t reach Total Needed, the selection stays short (our reading of SAP’s window description). A partner’s help page lists the same check.
  • Allocated to another document. Available Qty and Allocated Qty are separate columns. SAP says that if you select a batch allocated elsewhere you get an error message (it doesn’t quote the text, so it may not be this one), and that only the original document can remove the allocation. Open that document from the First Allocated Document column (SAP’s procedure page calls it First Allocated Batch), open its Batch Number Selection window and remove the allocation. Check with whoever owns that document first, because it loses the batch. SAP’s page: Using an Allocated Batch in a New Document.
  • The serial number is taken. SAP says a serial number can be allocated to one document only. Once it’s chosen, it’s no longer available. To free one, SAP has you open the other document from Allocated to Document and deselect it there.
  • The window is empty, and the item is On Release Only. With this method, batches aren’t created on receipt. Complete them first: Inventory > Item Management > Batches > Batch Management, Operation = Complete, or Batch Numbers Completion from the window’s Go To menu. Check the method on the item master, General tab, in Manage Item By and Management Method.
  • The warehouse changed. On serial items, SAP says changing the warehouse after selecting resets the selection, with a warning. Select again.
  • Bins. If the item is issued primarily by batch numbers, the Bin Location Allocation column must be fully allocated. Otherwise the field turns red and the document can’t be added. Automatic Allocation can fill it after you select batches. SAP doesn’t say this shows this exact message, so treat it as a check.

3. Receipts

For items managed On Every Transaction, receipts need numbers too (for example Goods Receipt PO, goods receipt, A/P invoice, A/R credit memo, receipt from production). In Batches – Setup, SAP says the document quantity must divide fully among the batches or the document can’t be added.

A negative quantity flips the rule. A receipt with a negative row needs a selection, and an issue with a negative row opens the window with a Create button.

4. Units of measure

If the row uses a different unit from inventory, check the units too. We found no SAP page that states a rule for this, so this section comes from reports:

  • Answering one Service Layer invoice case, SAP Support staff said: “In few cases, it can be related to UoM or Batch/Serial Number quantity”. That user fixed it by adding UoMEntry to the line (10.0, 2023).
  • Two DI API users (2017, 2022, neither thread answered) report -4014 only when an alternative unit is active on the line. A third, on 9.2 in 2018, concluded that sporadic errors came from rounding between batch quantity, line quantity and the unit factor, at 4 decimals in their case, and adjusted the line quantity before adding.

In the desktop client, SAP lets you show batch quantities by Document Row UoM or Inventory UoM (General Settings, Inventory tab, Display Batch Quantities By; since 9.3). Check which one you’re reading before you compare numbers.

5. In Data Transfer Workbench

All of this comes from users, plus one old SAP note that a user pasted into a thread in 2008. The posts run from 2008 to 2024, most don’t state a version, and a 2026 post on 10.0 has no answer. We found no SAP template reference page.

Documents with batches use three files. For an A/R invoice, users name them OINV - Documents, INV1 - Document_Lines and BTNT - BatchNumbers (SRNT for serial numbers).

  • Quantities must match. The line quantity and the batch quantities must add up, and users report that one mismatched row fails the file.
  • Link each batch to its line. BaseLineNumber in the batch file must match LineNum in the lines file. LineNum in the lines file counts from 0. Users disagree on what goes in LineNum in the batch file: some leave it blank, others use 0.
  • Inventory posting takes the variance. In one solved 2024 case on an inventory posting (HANA version, 9.3), the batch file needed the difference (for example -2), not the counted quantity. SAP’s window calls that area Batches Difference on inventory postings.
  • Don’t expect automatic selection. A partner, quoted by a user, says DTW has none. That user imported sales orders and selected batches when copying them to invoices.

6. In the DI API and Service Layer

Send the numbers on each row that issues a batch or serial item, and on each receipt row of an On Every Transaction item. This is our reading: we found no SAP statement that the DI API or Service Layer inherit or auto-select them from a base document, and SAP Support staff’s own example sends them explicitly. One DI API user (2013) who sent BaseType, BaseEntry and BaseLine with no batch rows got this error.

The row shapes below are Service Layer JSON, from SAP Support staff’s example (serial numbers, bins) and users’ payloads (batches). SAP’s Service Layer reference shows these fields only in pick list examples. In the DI API the same data sits on Lines.BatchNumbers, Lines.SerialNumbers and Lines.BinAllocations.

  • Batches: in each DocumentLines item, "BatchNumbers": [{"BatchNumber": "...", "Quantity": ...}], with the quantities adding up to the line.
  • Serial numbers: a SerialNumbers row with InternalSerialNumber, BaseLineNumber and Quantity. SAP’s SDK help calls SystemSerialNumber mandatory on outgoing documents, but SAP Support staff’s working example on FP 2102 leaves it out.
  • Bins: a DocumentLinesBinAllocations row with BinAbsEntry, Quantity, SerialAndBatchNumbersBaseLine and BaseLineNumber.
  • Changing batches on an existing sales order: on FP 2102, one user got this error on a PATCH. SAP Support staff told them to send the header B1S-ReplaceCollectionsOnPatch with the value true, and the user says it worked. Staff say it deletes the lines you leave out, so send every line you want to keep.
  • Pick lists: an SAP blog on the DI API (2017) says you can’t assign batches or serial numbers to a pick list until they’re assigned to the base sales order, so update the order first. A user adds that the client does this for you and the DI API doesn’t (2018, 9.3).
  • Sales or assembly BOMs: users quote SAP Note 972396 for this error on batch or serial components, and one poster lists the note for releases 2005 A to 8.82. In 2022, on 9.3, SAP Support staff pointed a Service Layer case to the same note and called it apparently a limitation. We couldn’t open the note, and we found no statement that it was fixed. Two workarounds are reported, and they pull in opposite directions. On a DI API A/R invoice in 2025: add a draft, reopen it, set batches on the child lines and convert it. That user says child rows added by hand only added extra lines. On a DI delivery in 2014: send the parent row with TreeType S and the child rows with TreeType I, each with its own batch row.

Messages that look similar

These are different errors with different fixes. The wordings come from users and SAP previews, and some are from old releases:

MessageWhat it points to
“The selected quantity of batch/serial numbers is greater than the open quantity.”Too much selected, the opposite problem
“Quantity falls into negative inventory”Stock, not selection
“You should use existing serial/batch numbers for this document type”Numbers that have to exist already
“Invalid “SerialAndBatchNumbersBaseLine”; specify a valid “SerialAndBatchNumbersBaseLine””The link from a bin row to a batch or serial row
“Cannot add document; sum of quantities on serials or batches is not the same as total quantity on line”Reported at production order close

Quick answers

Can I turn off batch management on the item to get past this?

Not quickly. SAP blocks changing Manage Item By unless stock and available serial and batch quantities are zero in all warehouses, and no open sales order or reserve invoice has allocated batches.

Does a copied document keep its batches?

It depends on the document. A sales order with allocated batches opens the window on Add and keeps the allocation for you to confirm or change. A return from a delivery, or a credit memo from an invoice, shows the base batches when it is fully based on that document. On an A/R invoice copied from a delivery, you can’t view the delivery’s batches.

Does a draft need numbers?

No, a draft can be saved without them. Numbers saved on a draft create no allocation, and SAP checks them when you create the real document, so it can refuse them until you reassign them.

Is it the batch status?

We don’t list this as a cause. One SAP page says Not Accessible and Locked batches can’t be released in certain documents, then says the status is informative only. Users disagree too, and no source ties status to this message.

Does this happen in the Web Client?

We found no report of this message there. SAP documents batch and serial selection in Web Client sales documents since FP 2105, and more documents in FP 2405. You type in the field or use its value help, then choose manual or automatic allocation.

If the message stays after these checks, send us the exact text, the document type, how it was posted and your SAP Business One version, and we’ll go through it with you.

Send us the error

SAP and SAP Business One are the trademarks or registered trademarks of SAP SE or its affiliates in Germany and in other countries. ZConsulto’s services are not produced or endorsed by SAP or by any other vendor named on this page.

← All guides