← All articles

How to query purchase order lines, schedules and distributions in Oracle Fusion

Query Oracle Fusion PO lines, delivery schedules and accounting distributions. Follow the resource hierarchy and preserve identifiers to avoid duplicate totals.

An Oracle Fusion PO line query needs to distinguish the ordered item from its delivery schedules and accounting distributions. One line can have several schedules, and one schedule can have several distributions. Repeating the line amount on each distribution row can overstate a report.

Resolve the order using the purchase-order status query. Keep its returned resource key. Read the order's line collection through GET /fscmRestApi/resources/11.13.18.05/purchaseOrders/{orderKey}/child/lines and select the intended line from the returned identifiers.

Retrieve its schedules using GET /fscmRestApi/resources/11.13.18.05/purchaseOrders/{orderKey}/child/lines/{lineId}/child/schedules. The placeholders must come from the selected order and line. Oracle's schedule reference describes the delivery details and accepted parameters.

Inspect the relevant delivery date and ship-to information on the schedule. Compare quantities and amounts only at the level where Oracle reports them, with the associated unit and currency. A service or amount-based line may require different interpretation from a quantity-based goods line.

For accounting detail, continue to GET /fscmRestApi/resources/11.13.18.05/purchaseOrders/{orderKey}/child/lines/{lineId}/child/schedules/{scheduleKey}/child/distributions. Oracle documents these distribution resources for accounting and project-related information. Resolve the schedule key from its own response.

Preserve the order, line, schedule and distribution identifiers in an export. Choose a row level before calculating totals. If the extract contains one row per distribution, sum distribution-level amounts only where their documented meaning matches the required measure. Do not sum duplicated header or line amounts across those rows.

This Oracle-documented SQL example follows line 1 of a synthetic standard PO through its schedules and distributions. Replace the order number and procurement business-unit ID. Oracle documents PO lines, schedules and distributions separately.

SELECT h.po_header_id,
       h.segment1 AS order_number,
       l.po_line_id,
       l.line_num,
       l.uom_code,
       s.line_location_id,
       s.shipment_num,
       s.schedule_status,
       d.po_distribution_id,
       d.distribution_num,
       d.code_combination_id,
       d.quantity_ordered,
       d.quantity_delivered,
       d.quantity_cancelled
FROM po_headers_all h
JOIN po_lines_all l
  ON l.po_header_id = h.po_header_id
LEFT JOIN po_line_locations_all s
  ON s.po_header_id = h.po_header_id
 AND s.po_line_id = l.po_line_id
LEFT JOIN po_distributions_all d
  ON d.po_header_id = h.po_header_id
 AND d.po_line_id = l.po_line_id
 AND d.line_location_id = s.line_location_id
WHERE h.segment1 = 'DEMO-PO-1042'
  AND h.prc_bu_id = 300100000000001
  AND h.type_lookup_code = 'STANDARD'
  AND l.line_num = 1
ORDER BY l.line_num, s.shipment_num, d.distribution_num;

Each populated distribution ID identifies the output's accounting row. The left joins retain a line or schedule with no matching child. Quantities belong to distributions and require the displayed unit of measure; amount-based services need their documented amount fields instead.

Check pagination on each child collection. Expanding children in the order response can simplify a small investigation, but it does not establish that every nested result was returned. Query large children directly and review completeness evidence. The pagination guide explains the relevant checks.

Fusion Toolkit's purchasing-investigation recipe reads a resolved order, supplier sites and the selected line's schedules and distributions. Review the supplied keys to confirm they belong to the same purchasing chain. This workflow was reviewed on 8 November 2026.

You can also use an LLM with the Fusion Toolkit AI Administrator skill and ask, "Show the delivery schedules and accounting distributions for line 1 of purchase order DEMO-PO-1042." It can inspect supported Oracle records without requiring you to write the queries. Identify the business unit and the line you need.