Postman collection
Stock Write

pixiRemoveItemFromPicklist

Removes a given quantity of an item, identified by barcode, from a bin on a picklist and returns a status row.

Removes picklist positions for one item and one bin from a picklist.

Steps:

  1. Quantity must be at least 1. NULL or smaller values return an error.
  2. The bin is looked up by its name (BinName) in InvBin.
  3. The item is looked up by its barcode (EanUpc), using the item codes with code type 1 (barcode).
  4. The call counts the picklist positions (PLitem rows linked to an order line) on the picklist for this bin and item. Each position counts as one piece.
  5. If no position is found, the call checks why and returns a specific error: the picklist does not exist, the picklist has no positions from this bin, or the item is not on the picklist in this bin.
  6. If fewer positions exist than Quantity, an error is returned and nothing is deleted.
  7. Otherwise, Quantity positions are removed, starting with the newest positions (highest position key, i.e. the bottom of the picklist). For the affected order lines the picklist reference (PickListNrUsed) is reset to NULL. All picking progress entries for this picklist, item and bin are deleted. After that, a cleanup of assigned boxes runs for picklists that are now empty.
  8. A SUCCESS row reports how many positions were deleted.

Notes

  • The deletion runs in its own transaction, or in a savepoint if a transaction is already open. If a database error occurs, the changes are rolled back and the error is written to the error log via log.InsertError. The call still returns SUCCESS in that case, with the message 0 items deleted from picklist. Treat a count of 0 as a failure.
  • All picking progress entries (PL_ItemPickingProgress) for the picklist, item and bin are deleted, not only the entries for the removed quantity.
  • The box cleanup is done by dbo.pixi_RemoveAssignedBoxesFromEmptyPicklist. Its definition is not attached, so its exact effects are not documented here.
  • The lookups and counts use NOLOCK. If several bins share the same name, or several items share the same barcode, it is not defined which one is used.

Tables used

InvBin · Read ItemCode · Read PLHeader · Read PLitem · Write Orderlines · Write PL_ItemPickingProgress · Write
SQL object:
dbo.pipiRemoveItemFromPicklist
Updated at 2026-10-30