Postman collection
Reports Read

pixiReportOrderOverview

Returns an overview of orders with billing address, order totals, net gross profit and currency, optionally filtered by order date and order number.

Returns one row per order from OrderHeader, joined with the linked address (AddrRef = AddrKey) and the order currency.

Filters

  • Date range: if OrderDateFrom is set, only orders whose OrderDate lies between OrderDateFrom and OrderDateTo (inclusive) are returned. If OrderDateTo is empty, it is set to the current date and time. If OrderDateFrom is empty, no date filter is applied, even if OrderDateTo is set.
  • Order number: if OrderNrStart is set, only orders with OrderNr >= OrderNrStart are returned.
  • Both filters are combined with AND.

Row limit and sort order

  • The number of rows is limited to RowCount (default 1000).
  • Rows are sorted by OrderNr descending, so the newest orders (highest order numbers) come first.

Calculated value

  • GrossProfit_Netto is the sum of Qty * (Price_Net - SupplPrice) over all order lines of the order.

Notes

  • According to the code comment, the gross profit is calculated from the standard supplier price stored on the order line at the time of order (SupplPrice). It is not comparable with other gross profit reports in Pixi.
  • GrossProfit_Netto is NULL for orders without order lines.
  • Orders without a matching address or currency are excluded because of the inner joins.
  • The date comparison uses BETWEEN on a datetime value. A date-only OrderDateTo (e.g. 2024-03-31) means midnight, so orders later on that day are not included. Pass the following day or a time of 23:59:59 instead.
  • Because rows are sorted descending and cut off by RowCount, OrderNrStart does not work as a forward paging cursor: you always get the highest order numbers that meet the filters. If more than RowCount orders match, the older ones are not returned.
  • RowCount is applied with SET ROWCOUNT. A value of 0 removes the limit.
  • All tables are read with NOLOCK, so uncommitted data may appear.
  • The call only reads data.

Tables used

OrderHeader · Read Addresses · Read Currency · Read Orderlines · Read
SQL object:
dbo.pipiReportOrderOverview
Updated at 2026-10-30