All tables
tables · table

sfindent

The sfindent table serves as the header record for Semi-Finished (SF) Indents. It captures high-level procurement requests, including the requesting department, intended supplier, purpose, and authorization status. It acts as the precursor to Semi-Finished Purchase Orders (sfpo).

Row count
46
Last entry
2025-12-23
Source
tables

Columns

16
ColumnTypeNullableMeaning
indexintegerNOPrimary Key (Internal)
compcodestringNOCompany Identifier
indentnointegerNOUnique Indent Document Number
indentdatedatetimeNODate the indent was created
supcodestringYESSuggested/Target Supplier Code
dpcodestringYESDepartment Code initiating request
delivdatedatetimeYESRequested Delivery Date
purposestringYESReason for procurement
usernamestringYESCurrent active user or system account
useraddstringYESUser who created the record
addtimestringYESTimestamp of creation
usermodstringYESUser who last modified the record
modtimestringYESTimestamp of last modification
printflagstringYESFlag indicating if document was printed
authflagstringYESAuthorization Status
lockstringYESConcurrency lock or status flag

Full documentation

### 1) Overview
 The `sfindent` table serves as the header record for **Semi-Finished (SF) Indents**. It captures high-level procurement requests, including the requesting department, intended supplier, purpose, and authorization status. It acts as the precursor to Semi-Finished Purchase Orders (`sfpo`).
 
 ### 2) Column Dictionary
 
 | Column | Type | Nullable | Meaning | Allowed Values | SQL Usage |
 | :--- | :--- | :--- | :--- | :--- | :--- |
 | **index** | integer | NO | Primary Key (Internal) | Auto-incrementing | `PRIMARY KEY` |
 | **compcode** | string | NO | Company Identifier | e.g., "DAS" | `JOIN`, `WHERE` |
 | **indentno** | integer | NO | Unique Indent Document Number | e.g., 2, 104 | `JOIN`, `FILTER` |
 | **indentdate** | datetime | NO | Date the indent was created | | `ORDER BY`, `RANGE` |
 | **supcode** | string | YES | Suggested/Target Supplier Code | e.g., "SI", "RF" | `JOIN` to `suppmas` |
 | **dpcode** | string | YES | Department Code initiating request | e.g., "PPC", "30" | `JOIN` to `dprt_mas` |
 | **delivdate** | datetime | YES | Requested Delivery Date | | Informational |
 | **purpose** | string | YES | Reason for procurement | e.g., "-", "Project X" | Informational |
 | **username** | string | YES | Current active user or system account | e.g., "system", "cstore" | Audit |
 | **useradd** | string | YES | User who created the record | | Audit |
 | **addtime** | string | YES | Timestamp of creation | | Audit |
 | **usermod** | string | YES | User who last modified the record | | Audit |
 | **modtime** | string | YES | Timestamp of last modification | | Audit |
 | **printflag** | string | YES | Flag indicating if document was printed | NULL, "Y", "N" | Logic |
 | **authflag** | string | YES | Authorization Status | "Y" (Yes), "N" (No) | `WHERE authflag = 'Y'` |
 | **lock** | string | YES | Concurrency lock or status flag | | Logic |
 
 ### 3) Relationships & Join Map
 
 The table is a central header for the semi-finished goods procurement workflow.
 
 #### Primary Joins (SCHEMA_MAP Verified):
 * **sfindentitem (Child Table)**: Join on `compcode` and `indentno`. This provides the specific items and quantities requested in the indent.
 * **sfpo (Purchase Order Header)**: Join on `compcode` and `indentno`. This tracks which Indents have been converted into Purchase Orders.
 * **suppmas (Supplier Master)**: Join `sfindent.supcode` to `suppmas.supcode`.
 * **dprt_mas (Department Master)**: Join `sfindent.dpcode` to `dprt_mas.dpcode`.
 
 #### Likely Joins (Inferred/Contextual):
 * **cpohdr / rmpotab**: Per `viewALLPO`, these tables are often unioned with `sfindent` logic to provide a comprehensive view of all procurement types (SF, RM, and Consumables).
 
 ---