Skip to content
D365 Reference

ProdTable

worksheet header

Production order header — one row per order carrying the item being built, order status and type, scheduled and actual dates, and the BOM and route it was created from

Module: Production ControlCompany-partitioned (DataAreaId)

Header & line

ProdTable is the header for its lines in ProdBOM.

Fields

25 fields · 1 key

KeyFieldEDTDescriptionTypeLengthFlags
KeyProdIdProdIdThe production order number — the natural key BOM lines and postings join back onstring20
ItemIdItemIdItem the order producesstring20
NameOrder description, defaulted from the item namestring60
ProdStatusOrder status across its life cycle (created through ended)enum
ProdTypeWhether this is a standard order or a vendor (subcontracted) orderenum
InventDimIdInventDimIdInventory-dimension combination the order produces into; join to InventDim to resolve site / warehousestring25
BOMIdBOMIdBOM header the order's material lines were copied fromstring20
RouteIdRouteIdRoute the order's operations were copied fromstring20
QtySchedQuantity the order is scheduled to producereal
QtyCalcEstimated quantity the order was cost-estimated atreal
QtyStUpStarted quantity — how much of the order has been released to productionreal
RemainInventPhysicalQuantity still to be reported as finishedreal
SchedStartScheduled start date — the primary analysis date for production loaddate
SchedEndScheduled end datedate
DlvDateDelivery date the order is due againstdate
StUpDateActual start date; unstarted orders carry the 1900-01-01 sentineldate
FinishedDateDate the order was reported as finished; unset rows carry the 1900-01-01 sentineldate
RealDateDate the order was ended (costed); unset rows carry the 1900-01-01 sentineldate
ProdPoolIdProduction pool the order is grouped under for scheduling and reportingstring
ProdGroupIdProduction group, used for ledger posting profilesstring
CollectRefProdIdProdIdReference production order — links a sub-production back to its parent orderstring20
InventRefTypeWhat kind of demand the order was created against (sales order, production, none…)enum
InventRefIdOrder number of the referenced demand document, per InventRefTypestring20
InventTransIdInventTransIdInventory transaction reference of the order's receipt — the lot the produced quantity lands onstring40
DefaultDimensionRecIdRecId of the order's default financial-dimension value set in DimensionAttributeValueSetint64

Field provenance: hand-curated.

Boilerplate SQL

Starting point for reading ProdTableon Databricks — enums are decoded, 1900-01-01 dates are wrapped to NULL, and the DataAreaId anchor is in place. Set your Unity Catalog location, company, and filter values below; they’re substituted into the SQL and the copy button.

Query parameters
-- ============================================================
-- Table  : ProdTable Production order header — one row per order carrying the item being built, order status and type, scheduled and actual dates, and the BOM and route it was created from
-- Purpose: Column-selected read of ProdTable — auto-generated from field metadata
-- Grain  : One row per company (dataareaid) + ProdId
-- Notes  : Auto-generated skeleton for Synapse Link / Fabric Link-landed F&O data (lowercase column names). Enums decoded inline where verified; datetimes stored in UTC; 1900-01-01 dates are sentinels mapped to NULL. System/audit columns omitted — see the quirks guide.
-- ============================================================
SELECT
  pr.prodid AS "The production order number — the natural key BOM lines and postings join back on",
  pr.itemid AS "Item the order produces",
  pr.name AS "Order description, defaulted from the item name",
  pr.prodstatus AS "Order status across its life cycle (created through ended)",  -- enum: decode pr.prodstatus via GlobalOptionsetMetadata join — see quirks guide #enums
  pr.prodtype AS "Whether this is a standard order or a vendor (subcontracted) order",  -- enum: decode pr.prodtype via GlobalOptionsetMetadata join — see quirks guide #enums
  pr.inventdimid AS "Inventory-dimension combination the order produces into; join to InventDim to resolve site / warehouse",
  pr.bomid AS "BOM header the order's material lines were copied from",
  pr.routeid AS "Route the order's operations were copied from",
  pr.qtysched AS "Quantity the order is scheduled to produce",
  pr.qtycalc AS "Estimated quantity the order was cost-estimated at",
  pr.qtystup AS "Started quantity — how much of the order has been released to production",
  pr.remaininventphysical AS "Quantity still to be reported as finished",
  pr.schedstart AS "Scheduled start date — the primary analysis date for production load",
  pr.schedend AS "Scheduled end date",
  pr.dlvdate AS "Delivery date the order is due against",
  CASE WHEN CAST(pr.stupdate AS DATE) = DATE '1900-01-01' THEN NULL ELSE CAST(pr.stupdate AS DATE) END AS "Actual start date; unstarted orders carry the 1900-01-01 sentinel",  -- 1900-01-01 sentinel → NULL
  CASE WHEN CAST(pr.finisheddate AS DATE) = DATE '1900-01-01' THEN NULL ELSE CAST(pr.finisheddate AS DATE) END AS "Date the order was reported as finished; unset rows carry the 1900-01-01 sentinel",  -- 1900-01-01 sentinel → NULL
  CASE WHEN CAST(pr.realdate AS DATE) = DATE '1900-01-01' THEN NULL ELSE CAST(pr.realdate AS DATE) END AS "Date the order was ended (costed); unset rows carry the 1900-01-01 sentinel",  -- 1900-01-01 sentinel → NULL
  pr.prodpoolid AS "Production pool the order is grouped under for scheduling and reporting",
  pr.prodgroupid AS "Production group, used for ledger posting profiles",
  pr.collectrefprodid AS "Reference production order — links a sub-production back to its parent order",
  pr.inventreftype AS "What kind of demand the order was created against (sales order, production, none…)",  -- enum: decode pr.inventreftype via GlobalOptionsetMetadata join — see quirks guide #enums
  pr.inventrefid AS "Order number of the referenced demand document, per InventRefType",
  pr.inventtransid AS "Inventory transaction reference of the order's receipt — the lot the produced quantity lands on",
  pr.defaultdimension AS "RecId of the order's default financial-dimension value set in DimensionAttributeValueSet"
FROM <catalog>.<schema>.prodtable pr
-- Dimension expansion: uncomment to resolve site / warehouse / location / batch
-- LEFT JOIN <catalog>.<schema>.inventdim id ON id.inventdimid = pr.inventdimid AND id.dataareaid = pr.dataareaid
-- Resolve DimensionAttributeValueSet (via DefaultDimension): uncomment to join on its RecId surrogate key
-- LEFT JOIN <catalog>.<schema>.dimensionattributevalueset dim ON dim.recid = pr.defaultdimension
WHERE
  pr.dataareaid = '<company>'
  -- AND pr.prodid = '<ProdId>'
  -- AND pr.schedstart >= '<DATE_FROM>'  -- yyyy-MM-dd (UTC)
  -- AND pr.schedstart <= '<DATE_TO>'  -- yyyy-MM-dd (UTC)
ORDER BY pr.prodid;

6 parameters not filled: <catalog>, <schema>, <company>, <ProdId>, <DATE_FROM>, <DATE_TO>

Relationships

1-hop neighbors — click a table to navigate there. RecId and InventDim edges are highlighted; they’re the joins newcomers most often get wrong.

Join details

  • ProdTableProdBOMheader line · 1:N
    ON prodtable.prodid = prodbom.prodid
  • ProdTableInventTableforeign key · N:1
    ON prodtable.itemid = inventtable.itemid
  • ProdTableBOMTableforeign key · N:1
    ON prodtable.bomid = bomtable.bomid
  • ProdTableRouteTableforeign key · N:1
    ON prodtable.routeid = routetable.routeid
  • ProdTableInventDimInventDim · N:1
    ON prodtable.inventdimid = inventdim.inventdimid
  • ProdTableDimensionAttributeValueSetRecId ref · N:1
    ON prodtable.defaultdimension = dimensionattributevalueset.recid

Data Entities That Expose This Table