MTL_ONHAND_QUANTITIES_DETAIL
Schema: INVtransactionPer inventory orgThe on-hand balance detail — receipt-level slices of stock per item, org, subinventory, locator, lot, and revision, consumed in FIFO order as material issues
Rows are FIFO receipt slices — SUM PRIMARY_TRANSACTION_QUANTITY at your chosen grain; a single row is not a balance
One item in one bin can hold many rows (one per receipt). On-hand at any grain is SUM(PRIMARY_TRANSACTION_QUANTITY) — or SUM(TRANSACTION_QUANTITY) in the row's own UOM — grouped by that grain; DATE_RECEIVED orders the slices (see quirks #onhand). Cost group, LPN, and project columns extend the grain in WMS and project-manufacturing orgs.
What the badges mean
- Schema: INV
- Schema: the Oracle product schema that owns the table (INV, ONT, WSH, PO, BOM, WIP, MRP, MSC, AR, AP, GL, HR, APPLSYS) — tells you which product family the object belongs to, not who can query it.
- master
- Data class: what the table holds — master data, transaction documents, control/configuration, interface/staging, or an APPS-schema view.
- OU-striped (ORG_ID)
- Rows are scoped to an operating unit. A landed extract carries every operating unit’s rows — filter or join on
ORG_ID, and don’t confuse it withORGANIZATION_ID(see the quirks guide). - Per inventory org
- Rows are scoped to an inventory organization (plant or warehouse) via
ORGANIZATION_ID— a different partition from OU-striped tables (see the quirks guide). - Language-striped
- The table carries a
LANGUAGEcolumn (a _TL translation table or FND_LOOKUP_VALUES) — one row per language. Filter to oneLANGUAGEor a join multiplies rows (see the quirks guide). - View
- This is an APPS-schema convenience view, not a physical table. Extract the base tables it joins instead — views can be slow at scale and aren't guaranteed stable across patches.
Structural facts — how the table is partitioned, not a trap by itself
Join & extract hazards — verify before you rely on this
Fields
16 fields · 1 key
16 fields.
| # | Field | Description | Type | Flags |
|---|---|---|---|---|
| 1 | ONHAND_QUANTITIES_ID | Surrogate key of the receipt slice — not a business identifier | NUMBER | Primary-key field |
| 2 | INVENTORY_ITEM_ID | Item id | NUMBER | |
| 3 | ORGANIZATION_ID | Inventory organization | NUMBER | |
| 4 | SUBINVENTORY_CODE | The subinventory holding the stock | VARCHAR2 | |
| 5 | LOCATOR_ID | The locator holding the stock — NULL in non-locator-controlled subinventories | NUMBER | |
| 6 | LOT_NUMBER | Lot — NULL for non-lot-controlled items | VARCHAR2 | |
| 7 | REVISION | Item revision — populated for revision-controlled items | VARCHAR2 | |
| 8 | PRIMARY_TRANSACTION_QUANTITY | The slice's quantity in the item's primary UOM — SUM this at your grain for on-hand | NUMBER | |
| 9 | TRANSACTION_QUANTITY | The slice's quantity in the transaction UOM it arrived in | NUMBER | |
| 10 | TRANSACTION_UOM_CODE | The UOM TRANSACTION_QUANTITY is expressed in (the transaction ledger spells its equivalent TRANSACTION_UOM) | VARCHAR2 | |
| 11 | DATE_RECEIVED | When the slice was received — orders the FIFO stack | DATE | The table's primary analysis date — a real DATE column, no conversion needed |
| 12 | ORIG_DATE_RECEIVED | The original receipt date, preserved across moves | DATE | |
| 13 | COST_GROUP_ID | Cost group of the slice (WMS/average-cost orgs) | NUMBER | |
| 14 | LPN_ID | License plate the stock sits on (WMS orgs) — extends the on-hand grain | NUMBER | |
| 15 | PROJECT_ID | Project the stock belongs to (project manufacturing orgs) | NUMBER | |
| 16 | TASK_ID | Task within the project | NUMBER |
Field provenance: hand-curated. 1 key field.
Boilerplate SQL
Starting point for reading MTL_ONHAND_QUANTITIES_DETAIL on Databricks — real DATE columns need no conversion, and the org anchor is already in place. The optional LAST_UPDATE_DATE watermark is included. Set your Unity Catalog location, schema, and org values below; they’re substituted into the SQL and the copy button.
6 parameters not filled: <catalog>, <schema>, <inventory_org_id>, <DATE_FROM>, <DATE_TO>, <watermark>
-- ============================================================
-- Table : MTL_ONHAND_QUANTITIES_DETAIL — The on-hand balance detail — receipt-level slices of stock per item, org, subinventory, locator, lot, and revision, consumed in FIFO order as material issues
-- Purpose: Column-selected read of MTL_ONHAND_QUANTITIES_DETAIL — auto-generated from field metadata
-- Grain : One row per inventory org (ORGANIZATION_ID) + ONHAND_QUANTITIES_ID
-- Caution: Rows are FIFO receipt slices — SUM PRIMARY_TRANSACTION_QUANTITY at your chosen grain; a single row is not a balance
-- Notes : Auto-generated skeleton for Oracle EBS R12 data landed in your lakehouse. Dates are real DATE/TIMESTAMP columns — no conversion needed. WHO audit columns omitted (see the quirks guide); the optional LAST_UPDATE_DATE watermark filter supports incremental extracts.
-- ============================================================
SELECT
t.ONHAND_QUANTITIES_ID AS "Surrogate key of the receipt slice — not a business identifier",
t.INVENTORY_ITEM_ID AS "Item id",
t.ORGANIZATION_ID AS "Inventory organization",
t.SUBINVENTORY_CODE AS "The subinventory holding the stock",
t.LOCATOR_ID AS "The locator holding the stock — NULL in non-locator-controlled subinventories",
t.LOT_NUMBER AS "Lot — NULL for non-lot-controlled items",
t.REVISION AS "Item revision — populated for revision-controlled items",
t.PRIMARY_TRANSACTION_QUANTITY AS "The slice's quantity in the item's primary UOM — SUM this at your grain for on-hand",
t.TRANSACTION_QUANTITY AS "The slice's quantity in the transaction UOM it arrived in",
t.TRANSACTION_UOM_CODE AS "The UOM TRANSACTION_QUANTITY is expressed in (the transaction ledger spells its equivalent TRANSACTION_UOM)",
t.DATE_RECEIVED AS "When the slice was received — orders the FIFO stack",
t.ORIG_DATE_RECEIVED AS "The original receipt date, preserved across moves",
t.COST_GROUP_ID AS "Cost group of the slice (WMS/average-cost orgs)",
t.LPN_ID AS "License plate the stock sits on (WMS orgs) — extends the on-hand grain",
t.PROJECT_ID AS "Project the stock belongs to (project manufacturing orgs)",
t.TASK_ID AS "Task within the project"
FROM <catalog>.<schema>.MTL_ONHAND_QUANTITIES_DETAIL t
WHERE
t.ORGANIZATION_ID = <inventory_org_id> -- inventory org, NOT the operating unit — see quirks guide #two-orgs
-- AND t.DATE_RECEIVED >= DATE '<DATE_FROM>'
-- AND t.DATE_RECEIVED <= DATE '<DATE_TO>'
-- AND t.LAST_UPDATE_DATE >= TIMESTAMP '<watermark>' -- WHO watermark, bulk-stamped by batch jobs; see quirks guide #who-columns
ORDER BY t.ONHAND_QUANTITIES_ID;Verified September 2026
Relationships
Diagram of 1-hop neighbors — join details below. FND lookup decode and translation edges are highlighted; they’re the joins newcomers most often get wrong.
Join details
ON MTL_ONHAND_QUANTITIES_DETAIL.INVENTORY_ITEM_ID = MTL_SYSTEM_ITEMS_B.INVENTORY_ITEM_ID AND MTL_ONHAND_QUANTITIES_DETAIL.ORGANIZATION_ID = MTL_SYSTEM_ITEMS_B.ORGANIZATION_IDON MTL_ONHAND_QUANTITIES_DETAIL.SUBINVENTORY_CODE = MTL_SECONDARY_INVENTORIES.SECONDARY_INVENTORY_NAME AND MTL_ONHAND_QUANTITIES_DETAIL.ORGANIZATION_ID = MTL_SECONDARY_INVENTORIES.ORGANIZATION_IDON MTL_ONHAND_QUANTITIES_DETAIL.LOCATOR_ID = MTL_ITEM_LOCATIONS.INVENTORY_LOCATION_ID AND MTL_ONHAND_QUANTITIES_DETAIL.ORGANIZATION_ID = MTL_ITEM_LOCATIONS.ORGANIZATION_IDON MTL_ONHAND_QUANTITIES_DETAIL.LOT_NUMBER = MTL_LOT_NUMBERS.LOT_NUMBER AND MTL_ONHAND_QUANTITIES_DETAIL.INVENTORY_ITEM_ID = MTL_LOT_NUMBERS.INVENTORY_ITEM_ID AND MTL_ONHAND_QUANTITIES_DETAIL.ORGANIZATION_ID = MTL_LOT_NUMBERS.ORGANIZATION_ID
More Inventory tables
- MTL_PARAMETERSInventory organization parameters — one row per inventory org, holding the short org code, the master org it points to, and the org's costing method and locator/lot/serial control defaults; the org list every ORGANIZATION_ID resolves against
- MTL_RESERVATIONSFirm reservations tying a demand source (a sales order line, most commonly) to a supply source (on-hand or expected supply) for an item in an org, optionally pinned down to subinventory, locator, and lot
- MTL_SECONDARY_INVENTORIESThe subinventory master — each row a named section of stock within an organization (stores, staging, WIP, rejects) with its asset/expense nature, tracking and reservability controls, and default accounts
- MTL_SERIAL_NUMBERSThe serial number master — definition and current position (status, org, subinventory, locator, lot) of every serialized unit; a serial is unique per item, not per org
- MTL_SUPPLYThe incoming-supply picture — one row per open requisition, purchase order, or in-transit shipment element expected into an org, with the supply type migrating as the document progresses
- MTL_TRANSACTION_ACCOUNTSAccounting distributions for material transactions — the debit and credit lines behind each material transaction, valued and pointed at a GL account combination