All tables
tables · table

tempitempipeline

The tempitempipeline table is a temporary analytical or staging table used within the SQL Server environment to track the flow of items through various production stages and operations. It serves as a "pipeline" report, aggregating data on opening balances, production quantities across multiple stages (1st and 2nd), issues for job work, online rejections, and quantities currently in process.

Row count
6
Last entry
Source
tables

Columns

24
ColumnTypeNullableMeaning
indexintegerNoPrimary key / Row identifier.
compcodestringNoCompany identifier.
itemcodestringNoUnique identifier for the manufactured item.
oprcodestringNoOperation code representing the current production step.
pisnointegerNoProcess Instruction Sequence Number; defines the order of operations.
opbalnumberYesOpening balance at the start of this operation stage.
sfpurnumberYesSemi-finished purchase quantity.
prodistnumberYesProduction quantity from the 1st stage or distribution.
mrpistnumberYesMRP related quantity for the 1st stage.
prod2ndnumberYesProduction quantity from the 2nd stage.
mrp2ndnumberYesMRP related quantity for the 2nd stage.
issprod2ndnumberYesQuantity issued for 2nd stage production.
issjob2ndnumberYesQuantity issued for 2nd stage job work.
storenumberYesQuantity currently held in the warehouse/store.
saleqtynumberYesTotal quantity sold or dispatched.
onlinerejnumberYesQuantity rejected during the online production process.
totalstringYesLikely a placeholder for aggregated string data or totals.
forIssQtynumberYesQuantity available for issue to the next stage.
ProddonenumberYesTotal production completed in this operation.
RWQtynumberYesRework Quantity.
ScrapQtynumberYesTotal scrap generated in this operation.
OnProcessQtynumberYesQuantity currently residing on the shop floor.
scheduleqtynumberYesPlanned or scheduled quantity for the item.
onlinerejSnumberYesOnline rejection quantity (secondary or summary).

Full documentation

### 1) Overview
 The `tempitempipeline` table is a temporary analytical or staging table used within the SQL Server environment to track the flow of items through various production stages and operations. It serves as a "pipeline" report, aggregating data on opening balances, production quantities across multiple stages (1st and 2nd), issues for job work, online rejections, and quantities currently in process. 
 
 The table is structured to show a sequence of operations (guided by `pisno`) for a specific item, allowing for a granular view of work-in-progress (WIP), scrap, and final store availability.
 
 ### 2) Column Dictionary
 
 | Column | Type | Nullable | Meaning | Allowed Values | SQL Usage |
 | :--- | :--- | :--- | :--- | :--- | :--- |
 | **index** | integer | No | Primary key / Row identifier. | Auto-incrementing | `WHERE index = 0` |
 | **compcode** | string | No | Company identifier. | e.g., "DAS" | `JOIN` key |
 | **itemcode** | string | No | Unique identifier for the manufactured item. | e.g., "CP-030" | `JOIN` key |
 | **oprcode** | string | No | Operation code representing the current production step. | e.g., "HARD", "FINAL" | `JOIN` key |
 | **pisno** | integer | No | Process Instruction Sequence Number; defines the order of operations. | 1, 2, 3... 99 | `ORDER BY pisno` |
 | **opbal** | number | Yes | Opening balance at the start of this operation stage. | Decimal | Calculation |
 | **sfpur** | number | Yes | Semi-finished purchase quantity. | Decimal | Calculation |
 | **prodist** | number | Yes | Production quantity from the 1st stage or distribution. | Decimal | Calculation |
 | **mrpist** | number | Yes | MRP related quantity for the 1st stage. | Decimal | Calculation |
 | **prod2nd** | number | Yes | Production quantity from the 2nd stage. | Decimal | Calculation |
 | **mrp2nd** | number | Yes | MRP related quantity for the 2nd stage. | Decimal | Calculation |
 | **issprod2nd** | number | Yes | Quantity issued for 2nd stage production. | Decimal | Calculation |
 | **issjob2nd** | number | Yes | Quantity issued for 2nd stage job work. | Decimal | Calculation |
 | **store** | number | Yes | Quantity currently held in the warehouse/store. | Decimal | Calculation |
 | **saleqty** | number | Yes | Total quantity sold or dispatched. | Decimal | Calculation |
 | **onlinerej** | number | Yes | Quantity rejected during the online production process. | Decimal | Calculation |
 | **total** | string | Yes | Likely a placeholder for aggregated string data or totals. | NULL in samples | Display |
 | **forIssQty** | number | Yes | Quantity available for issue to the next stage. | Decimal | Calculation |
 | **Proddone** | number | Yes | Total production completed in this operation. | Decimal | Calculation |
 | **RWQty** | number | Yes | Rework Quantity. | Decimal | Calculation |
 | **ScrapQty** | number | Yes | Total scrap generated in this operation. | Decimal | Calculation |
 | **OnProcessQty** | number | Yes | Quantity currently residing on the shop floor. | Decimal | Calculation |
 | **scheduleqty** | number | Yes | Planned or scheduled quantity for the item. | Decimal | Planning |
 | **onlinerejS** | number | Yes | Online rejection quantity (secondary or summary). | Decimal | Calculation |
 
 ### 3) Relationships & Join Map
 
 The table functions as a junction for production flow and can be joined to master data and transaction logs using `compcode`, `itemcode`, and `oprcode`.
 
 #### Primary Joins (SCHEMA_MAP Verified):
 * **Item Master:** `dbo.itemmas` via `compcode`, `itemcode` (To fetch item descriptions, units, and categories).
 * **Operation Master:** `dbo.oprmas` via `compcode`, `oprcode` (To fetch full operation names).
 * **Item Operations:** `dbo.itemopr` via `compcode`, `itemcode`, `oprcode` (To fetch sequence `pisno` or operation rates).
 * **Production Records:** `dbo.product2` via `compcode`, `itemcode`, `oprcode` (To reconcile actual daily production against pipeline totals).
 * **Rejection Tracking:** `dbo.onlinerej_dtl` via `compcode`, `itemcode`, `oprcode` (To break down `onlinerej` by reason).
 
 #### Secondary Joins (Likely):
 * **Schedule Data:** `dbo.scheduledtl` via `compcode`, `itemcode` (To compare `scheduleqty` against pipeline throughput).
 * **Inventory Ledger:** `dbo.itemledger` via `compcode`, `itemcode` (To verify `store` balances).