Skip to main content
One row per current purchase-order line from your ERP or OMS (GoodDay and Pipe17), with vendor details, PO status, destination location, SKU, quantities, vendor cost inputs, derived landed cost per unit, and inbound shipment dates.
  • Grain: One row per (sm_store_id, source_system, purchase_order_line_id).
  • Date fields: purchase_order_date, planned_ready_date, expected_fulfillment_date, actual_fulfillment_date, shipment_expected_arrival_date, and shipment_actual_arrival_date.
  • Filters to start with: source_system (goodday or pipe17), especially if you keep the same purchase order in both systems.
  • Joins: Join obt_inventory_positions on lower(trim(po.sku)) = inv.sku (and sm_store_id), because obt_inventory_positions.sku is lowercased and trimmed while obt_purchase_order_lines.sku preserves source casing. Join dim_product_variants on sku (and sm_store_id) for catalog attributes.

When to use this table

Use obt_purchase_order_lines to track open purchase orders, inbound inventory arriving by SKU and location, vendor lead times, and unit landed cost breakdowns (vendor price, freight, fees, tariffs, and duties).
If you manage the same purchase order in both GoodDay and Pipe17, it appears once per system. Filter on source_system before summing ordered_units, received_units, open_units, or extended_landed_cost so you do not double-count.

Reading the columns

  • Open units: open_units is ordered_units minus received_units, clamped at zero so over-receipts never produce negative open units.
  • Landed cost: landed_cost_per_unit is vendor_price * (1 + tariff_rate + duty_rate) + freight_price + fees. It is NULL whenever any required input is missing, including on every Pipe17 line (Pipe17 records vendor price, not freight, duty, or fee inputs). extended_landed_cost is landed_cost_per_unit * ordered_units.
  • Currency: Prices and costs are denominated in currency_code. Group or filter by currency_code before summing costs across multi-currency purchase orders.

Example: open purchase-order units and value by SKU

Columns