tables · table
tempFGlotqty
The tempFGlotqty table is a temporary staging or working table used to store and aggregate accepted quantities (acptqty) for Finished Goods (FG) at a granular lot and sub-lot level. It facilitates traceability by linking specific production batches (lotno, sublotno) and material batches (heatno) to their respective company entities. This table is typically utilized during inventory reconciliation, quality inspection processing, or report generation for Finished Goods.
Row count
81
Last entry
—
Source
tables
Columns
7| Column | Type | Nullable | Meaning |
|---|---|---|---|
index | integer | NO | Primary key for the temporary record set. |
compcode | string | YES | Unique identifier for the company/legal entity. |
lotno | string | YES | The primary production lot identifier. |
acptqty | integer | YES | The quantity of items accepted after quality check. |
heatno | string | YES | The raw material melt/batch number for traceability. |
sublotno | string | YES | A secondary identifier for further lot segregation. |
variant | string | YES | Code identifying product design or material variants. |
Full documentation
### 1) Overview The `tempFGlotqty` table is a temporary staging or working table used to store and aggregate accepted quantities (`acptqty`) for Finished Goods (FG) at a granular lot and sub-lot level. It facilitates traceability by linking specific production batches (`lotno`, `sublotno`) and material batches (`heatno`) to their respective company entities. This table is typically utilized during inventory reconciliation, quality inspection processing, or report generation for Finished Goods. ### 2) Column Dictionary | Column | Type | Nullable | Meaning | Allowed Values | SQL Usage | | :--- | :--- | :--- | :--- | :--- | :--- | | **index** | integer | NO | Primary key for the temporary record set. | Auto-incrementing integers | `WHERE index = 0` | | **compcode** | string | YES | Unique identifier for the company/legal entity. | e.g., "DAS" | `JOIN ... ON a.compcode = b.compcode` | | **lotno** | string | YES | The primary production lot identifier. | e.g., "25190" | `GROUP BY lotno` | | **acptqty** | integer | YES | The quantity of items accepted after quality check. | > 0 | `SUM(acptqty)` | | **heatno** | string | YES | The raw material melt/batch number for traceability. | e.g., "0", "H-101" | `WHERE heatno <> ''` | | **sublotno** | string | YES | A secondary identifier for further lot segregation. | e.g., "25190" | `JOIN ... ON a.sublotno = b.sublotno` | | **variant** | string | YES | Code identifying product design or material variants. | e.g., "V1", NULL | `WHERE variant IS NULL` | ### 3) Relationships & Join Map Based on the `SCHEMA_MAP`, `tempFGlotqty` functions as a bridge between production tracking and inventory management. #### Primary Join Targets (Strictly SCHEMA_MAP Grounded): * **dbo.fghdr (Finished Goods Header):** * *Logic:* Links temporary lot quantities to official FG transaction records. * *Join Columns:* `compcode`, `lotno`, `heatno`, `variant`. * **dbo.product2 / dbo.RMproduct1 (Production Records):** * *Logic:* Connects accepted lot quantities back to specific production runs or raw material processing. * *Join Columns:* `compcode`, `lotno`, `sublotno`, `heatno`. * **dbo.templotqty (Temporary Lot Management):** * *Logic:* Likely a twin table or related staging table sharing the exact same structure for intermediate processing. * *Join Columns:* `compcode`, `lotno`, `sublotno`, `heatno`, `variant`. * **dbo.invdtl / dbo.Performainvdtl (Invoice Details):** * *Logic:* Facilitates checking if a specific production lot has been invoiced or is pending dispatch. * *Join Columns:* `compcode`, `lotno`. #### Likely Joins (Inferred): * **dbo.ScrapChallan:** Can be joined on (`compcode`, `lotno`, `sublotno`) to compare accepted quantities vs. scrapped quantities for a specific batch.