Postman collection
Orders Read

pixiGetShippableOrders

Returns the order lines of orders that can be shipped completely from stock, or a summary of those orders.

Wrapper around pipiReportGetShippableOrders. ShowDetails is converted to a bit and passed as @ViewDetails. The remaining options are fixed: no partial deliveries, no shop filter, @IncludeOrdersWithAnyShipDate = 0, per-location output off.

Which orders are considered

  • Order lines with status ANG or EIN, an item reference (ItemRef not NULL) and Qty > 0.
  • The order must belong to an existing customer.
  • Neither the shipping address nor the billing address of the order may be locked (ASlocked = 'Y').
  • The order must not be locked (OhSLocked = 'Y').
  • The ship date must be empty or earlier than tomorrow. Orders with a ship date in the future are excluded.

Stock check

  • Stock is calculated per line by pixi_CalculateStockForOrderLines, using the locations with SpecialStock = 0.
  • Only complete orders are returned. If a single line of an order is not shippable, the whole order is left out.

Output

  • ShowDetails ≠ 0 (default 1): one row per order line, sorted by OrderNr and OrderlineRef.
  • ShowDetails = 0 or NULL: a single summary row with the number of orders, the order total (sum of Price * Qty), the summed shipping cost and the number of picks (sum of Qty).

Currency

  • If the setting MultiCurrencyEnabled is active, prices and shipping costs are converted into the database currency. The conversion uses the exchange rate of the same date, and the currency code is returned in dbCurrency.
  • Otherwise the values stay in the order currency and dbCurrency is NULL.

Notes

  • All reads use NOLOCK, so results may include uncommitted data.
  • The stock calculation in pixi_CalculateStockForOrderLines is not attached, so its exact rules (reservations, minimum stock) cannot be documented here. It is called with @SkipZeroStockItemsCalc = 1.
  • With multi-currency enabled, the code divides by 1 if no matching exchange rate is found. In that case the value silently stays in the order currency.
  • In detail mode, ShipCost is the shipping cost of the whole order and is repeated on every line. Do not add it up per line.
  • In summary mode, shipping costs are summed over distinct OrderNr/ShipCost pairs.
  • If no orders qualify, the summary row still returns Orders = 0 and ShipCost = 0; OrderTotal and Picks are then NULL.
  • For partial deliveries, shop filters or per-location output, call pixiReportGetShippableOrders directly.

Tables used

OrderStates · Read Orderlines · Read OrderHeader · Read Customers · Read Addresses · Read ExchRate · Read Location · Read
SQL object:
dbo.pipiGetShippableOrders
Updated at 2026-10-30