tables · table
cpohdramnd
The cpohdramnd table serves as the Purchase Order Header Amendment repository. It stores the historical revisions and modifications made to general Purchase Orders (non-RM/non-SF types). Each record represents a specific version (amendno) of a PO, capturing changes in terms, delivery dates, values, and the justification for the amendment (reason). It is the transactional parent to cpodtlamnd.
Row count
1,885
Last entry
2026-04-25
Source
tables
Columns
32| Column | Type | Nullable | Meaning |
|---|---|---|---|
index | integer | No | Primary Key (Internal) |
compcode | string | No | Company Identifier |
pono | integer | No | Purchase Order Number |
amendno | integer | No | Amendment Revision Number |
invyear | integer | No | Financial Year of PO |
type | string | Yes | PO Category/Type |
podate | datetime | Yes | Original PO Date |
supcode | string | Yes | Supplier Unique Code |
indentno | integer | Yes | Reference Indent Number |
delivery | datetime | Yes | Expected Delivery Date |
f_o_r | string | Yes | Freight Terms (Freight On Road) |
refdate | datetime | Yes | Reference/Indent Date |
quotationno | string | Yes | Vendor Quotation Number |
quotationdate | datetime | Yes | Vendor Quotation Date |
amenddate | datetime | Yes | Date this revision was created |
reason | string | Yes | Justification for Amendment |
remarks | string | Yes | Internal Notes |
authflag | integer | Yes | Authorization Status |
wefdate | datetime | Yes | With Effect From (Effective Date) |
povalue | string | Yes | Total Value of PO |
povalueword | string | Yes | PO Value in words |
cname | string | Yes | Currency Name |
consignee | string | Yes | Consignee identifier |
podoc | string | Yes | Document Path/Filename |
cancel_flag | string | Yes | Cancellation Status |
location | string | Yes | Warehouse/Plant Location |
check_flag | number | Yes | Verification/Quality Check Flag |
check_flag_user | string | Yes | User who verified the record |
cpodtlamnd | `compcode`, `pono`, `invyear`, `amendno` | High | Retrieving amended line items for a specific PO version. |
suppmas | `compcode`, `supcode` | Medium | Fetching vendor address and GST details. |
company | `compcode` | Low | Company header information. |
cmrpreq | `compcode`, `indentno` | Low | Linking back to the material requirement (Indent). |
Full documentation
### 1) Overview The `cpohdramnd` table serves as the **Purchase Order Header Amendment** repository. It stores the historical revisions and modifications made to general Purchase Orders (non-RM/non-SF types). Each record represents a specific version (`amendno`) of a PO, capturing changes in terms, delivery dates, values, and the justification for the amendment (`reason`). It is the transactional parent to `cpodtlamnd`. ### 2) Column Dictionary | Column | Type | Nullable | Meaning | Allowed Values | SQL Usage | | :--- | :--- | :--- | :--- | :--- | :--- | | **index** | integer | No | Primary Key (Internal) | | Primary Key | | **compcode** | string | No | Company Identifier | e.g., "DAS" | FK to `company` | | **pono** | integer | No | Purchase Order Number | | Join Key | | **amendno** | integer | No | Amendment Revision Number | 0 = Original, 1+ = Revisions | Join Key | | **invyear** | integer | No | Financial Year of PO | e.g., 2013, 2014 | Join Key | | **type** | string | Yes | PO Category/Type | e.g., "CS" | | | **podate** | datetime | Yes | Original PO Date | | Filter | | **supcode** | string | Yes | Supplier Unique Code | e.g., "MAXFEED" | FK to `suppmas` | | **indentno** | integer | Yes | Reference Indent Number | | FK to `cmrpreq` | | **delivery** | datetime | Yes | Expected Delivery Date | | | | **f_o_r** | string | Yes | Freight Terms (Freight On Road) | e.g., "ROHTAK", "EX-WORKS" | | | **term_1** to **term_7** | string | Yes | Contractual Terms & Conditions | | | | **refdate** | datetime | Yes | Reference/Indent Date | | | | **quotationno** | string | Yes | Vendor Quotation Number | | | | **quotationdate** | datetime | Yes | Vendor Quotation Date | | | | **amenddate** | datetime | Yes | Date this revision was created | | | | **reason** | string | Yes | Justification for Amendment | | Documentation | | **remarks** | string | Yes | Internal Notes | | | | **authflag** | integer | Yes | Authorization Status | 0: Pending, 1: Authorized | Filter | | **wefdate** | datetime | Yes | With Effect From (Effective Date) | | Filter | | **povalue** | string | Yes | Total Value of PO | | | | **povalueword** | string | Yes | PO Value in words | | | | **cname** | string | Yes | Currency Name | e.g., "Rs" | | | **consignee** | string | Yes | Consignee identifier | | FK to `suppmas` (Likely) | | **podoc** | string | Yes | Document Path/Filename | | | | **cancel_flag** | string | Yes | Cancellation Status | "Y", Null | Filter | | **location** | string | Yes | Warehouse/Plant Location | | FK to `location` | | **check_flag** | number | Yes | Verification/Quality Check Flag | | | | **check_flag_user** | string | Yes | User who verified the record | | | --- ### 3) Relationships & Join Map #### Logical Relationships * **One-to-Many**: One PO Header Amendment (`cpohdramnd`) has multiple item lines in `cpodtlamnd`. * **Many-to-One**: Multiple amendments belong to one Supplier (`suppmas`). * **Many-to-One**: References a specific Financial Year and Company. #### Join Rules & Authority * **Primary Join (Detail)**: Join with `cpodtlamnd` using `compcode`, `pono`, `invyear`, and `amendno`. * **Supplier Lookup**: Join with `suppmas` using `compcode` and `supcode`. * **Location Lookup**: Join with `location` table using `compcode` and `location`. | Target Table | Join Columns | Priority | Context | | :--- | :--- | :--- | :--- | | **cpodtlamnd** | `compcode`, `pono`, `invyear`, `amendno` | High | Retrieving amended line items for a specific PO version. | | **suppmas** | `compcode`, `supcode` | Medium | Fetching vendor address and GST details. | | **company** | `compcode` | Low | Company header information. | | **cmrpreq** | `compcode`, `indentno` | Low | Linking back to the material requirement (Indent). | | **location** | `compcode`, `location` | Low | Identifying the physical plant/site. |