MAINVMSG – Invoice and PO Cost Message

System
Matching (MA)
Prefix
MAG
Primary key
COMPANY, VENDOR, INVOICE, SUFFIX, CANCEL-SEQ, MAD-SEQ-NBR, SEQ-NBR
Fields
36
Updated by
34 programs
Referenced by
14 programs

MAINVMSG is the Invoice and PO Cost Message table in Lawson Matching (prefix MAG). It is indexed by COMPANY, VENDOR, INVOICE, SUFFIX, CANCEL-SEQ, MAD-SEQ-NBR, SEQ-NBR (MAGSET1); alternate indexes: MAGSET10, MAGSET2, MAGSET3, MAGSET4, MAGSET5, MAGSET6, MAGSET7, MAGSET8 and 1 more. It is related 1:M to POMATCHOBJ. It is updated by AP20.1, AP20.2, AP20.3, AP20.4, AP20.5, AP20.7, AP21.1, AP23.1 and 26 more and referenced by MA264, MA67.3, MA68.3, MA90.2, MA90.3, MA90.5, MA90.6, MM280 and 6 more. The table has 36 fields, 10 indexes and 1 documented relation.

About MAINVMSG

No description in the Lawson data dictionary.

Fields (36)

Column = COBOL field name without the MAG- prefix, hyphens → underscores. Derived fields are computed by the application and are not stored. PK = primary key (present in every index); SETn = leading/alternate key of that index.

Field / columnTypeDescription & valuesUpdated by
#MAG-COMPANY PK
COMPANY
Numeric 4Identifies the AP company if the resource type = V. Identifies the HR company if the resource type = E. It is blank for type A, P or Q resources.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.1, MA66.2, MA66.3 +2 more
#MAG-AUTH-CODE SET10 SET2 SET3 SET4 SET6 SET8 SET9
AUTH_CODE
Alpha 3A user-defined code representing a person or department responsible for approving a registered invoice.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.1, MA66.2, MA66.3 +2 more
#MAG-VENDOR PK
VENDOR
Alpha 9 (Right Justified)The vendor's identification code.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.1, MA66.2, MA66.3 +2 more
#MAG-INVOICE PK
INVOICE
Alpha 22Used to identify the invoice.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.1, MA66.2, MA66.3 +2 more
#MAG-SUFFIX PK
SUFFIX
Numeric 3This is the suffix for the invoice.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.1, MA66.2, MA66.3 +2 more
#MAG-CANCEL-SEQ PK
CANCEL_SEQ
Numeric 4An automatically assigned sequence number.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.1, MA66.2, MA66.3 +2 more
#MAG-PO-NUMBER SET2
PO_NUMBER
Alpha 14 (Right Justified)This field contains the number representing the purchase order.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-PO-RELEASE SET2
PO_RELEASE
Numeric 4Used to identify a purchase order release (created from a Blanket or Standing order).API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-PO-CODE SET2
PO_CODE
Alpha 4This is the purchase order code.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-PO-LINE-NBR SET2
PO_LINE_NBR
Numeric 6This field contains the line number.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-MAD-SEQ-NBR PK
MAD_SEQ_NBR
Numeric 4An automatically assigned sequence number.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.1, MA66.2, MA66.3 +2 more
#MAG-SEQ-NBR PK
SEQ_NBR
Numeric 4An automatically assigned sequence number.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.1, MA66.2, MA66.3 +2 more
#MAG-API-OBJ-ID SET10 SET2 SET3 SET4 SET5 SET7 SET8 SET9
API_OBJ_ID
Numeric 12This is the object identifier. It is used to relate commitments or posted transactions back to the originating subsystems. Each subsystem record that is updated as a commitment or posted transaction is assigned an object identifier. The object identifier is maintained in the subsystem files and in the Activity Commitments Detail and Activity Transaction files. The object identifier is a unique key used to drill back from Activity Management to the subsystems.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-MSG-ORIGIN SET7 SET8
MSG_ORIGIN
Alpha 1—
  • 1 PO Cost
  • 2 Recon Match
  • 3 DropShip
  • 4 Service
API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-ITEM SET3
ITEM
Alpha 32This field contains the item identifier.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.1, MA66.2, MA66.3 +2 more
#MAG-MATCH-DTL-KEY SET4
MATCH_DTL_KEY
Alpha 85—API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-STATUS SET7 SET8
STATUS
Numeric 1This field displays the status of the transaction.
  • 0 Unreleased
  • 1 Open
  • 2 Pending Action
  • 9 Closed
API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA64.9, MA66.2, MA66.3 +2 more
#MAG-ACTION
ACTION
Alpha 1" " = Open
  • 1 Approved
  • 2 Chargeback
  • 3 Disapprove
  • 4 Forward
  • 5 Accept Cost
  • 6 Adjust Cost
  • 7 Chargeback netted to zero
API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA64.9, MA66.2, MA66.3 +2 more
#MAG-OPERATOR SET7
OPERATOR
Alpha 10This field is used to store the login id of the person who entered the record.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-CREATE-DATE SET7 SET8
CREATE_DATE
Numeric 8 (yyyymmdd)The creation date.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-CREATE-TIME
CREATE_TIME
Numeric 6 (hhmmss)—API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-PROCURE-GROUP
PROCURE_GROUP
Alpha 4This field contains the identifier for a group of companies that share a common procurement effort. They buy items and services together.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-BUYER-CODE
BUYER_CODE
Alpha 3—API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-AUTH-CODE-MAIL
AUTH_CODE_MAIL
Alpha 30—API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-FWD-AUTH-OPER
FWD_AUTH_OPER
Alpha 10This field is used to store the login id of the person who entered the record.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA64.9, MA66.2, MA66.3 +2 more
#MAG-TYPE SET10 SET3 SET4 SET9
TYPE
Alpha 2This identifies whether this record is created because of a picking transaction, or because of a return. Valid values are: "IS" = Picking transaction. "RR" = Return. ~$1 VENDOR The vendor's identification code.
  • C Cost
  • Q Quantity
  • I Item
  • NR No Receipt Line
API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-VAR-TYPE SET10 SET3 SET4 SET9
VAR_TYPE
Alpha 1The Variance Type field contains the value that represents the variance type for fiscal year variances. Valid values are: " " = Item Difference
  • A Variance Amount
  • P Variance Percent
  • O Invoice Over Receipt
  • U Invoice Under Receipt
API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-REASON-CODE
REASON_CODE
Alpha 4This field contains the reason code, which indicates the cause for credit memos.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA64.9, MA66.2, MA66.3 +2 more
#MAG-PRIORITY
PRIORITY
Numeric 1Indicates order of precedence for contracts to determine costing defaults for items.
  • 1 Urgent
  • 2 Normal
API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.1, MA66.2, MA66.3 +2 more
#MAG-MATCH-OBJ-ID
MATCH_OBJ_ID
Numeric 12This is the object identifier. It is used to relate commitments or posted transactions back to the originating subsystems. Each subsystem record that is updated as a commitment or posted transaction is assigned an object identifier. The object identifier is maintained in the subsystem files and in the Activity Commitments Detail and Activity Transaction files. The object identifier is a unique key used to drill back from Activity Management to the subsystems.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-RESPOND-DATE SET7 SET8
RESPOND_DATE
Numeric 8 (yyyymmdd)This field displays the system date when this was created.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA64.9, MA66.1, MA66.2 +3 more
#MAG-DISC-DATE
DISC_DATE
Numeric 8 (yyyymmdd)This field displays the system date when this was created.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-LOCATION
LOCATION
Alpha 5This field contains a valid stocking location within the company inventory.API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA66.2, MA66.3, MAI1.1 +1 more
#MAG-PO-COST-UPD
PO_COST_UPD
Signed 18.5—API1.1, MA43.1, MA43.3, MA44.1, MA64.6, MA64.9, MA66.2, MA66.3 +2 more
#MAG-VEN-ITEM SET9
VEN_ITEM
Alpha 32—API1.1, MA43.1, MA43.3, MA44.1, MA66.2, MA66.3, MAI1.1, POI3.1
#MAG-GTIN SET10
GTIN
Numeric 14—MA43.1, MA43.3, MA44.1, MA66.2, MA66.3, MAI1.1

Indexes (10)

Keys are listed in index order; ↓ marks a descending key. Every documented Lawson index is unique unless flagged Duplicates; Subset indexes carry a Where condition.

IndexKeysFlagsConditionUsed in
MAGSET1
  1. COMPANY
  2. VENDOR
  3. INVOICE
  4. SUFFIX
  5. CANCEL-SEQ
  6. MAD-SEQ-NBR
  7. SEQ-NBR
PrimaryAP30.4, MA42.1, MA43.1, MA43.3, MA44.1, MA60.3, MA64.1, MA64.4 +13 more
MAGSET10
  1. COMPANY
  2. AUTH-CODE
  3. GTIN
  4. VAR-TYPE
  5. TYPE
  6. API-OBJ-ID
  7. MAD-SEQ-NBR
  8. SEQ-NBR
SubsetWhere STATUS = 1—
MAGSET2
  1. COMPANY
  2. AUTH-CODE
  3. PO-NUMBER
  4. PO-RELEASE
  5. PO-CODE
  6. INVOICE
  7. PO-LINE-NBR
  8. MAD-SEQ-NBR
  9. VENDOR
  10. API-OBJ-ID
  11. SEQ-NBR
KeyChange, SubsetWhere STATUS = 1MA64.2
MAGSET3
  1. COMPANY
  2. AUTH-CODE
  3. ITEM
  4. VAR-TYPE
  5. TYPE
  6. API-OBJ-ID
  7. MAD-SEQ-NBR
  8. SEQ-NBR
KeyChange, SubsetWhere STATUS = 1MA64.3
MAGSET4
  1. COMPANY
  2. AUTH-CODE
  3. MATCH-DTL-KEY
  4. VAR-TYPE
  5. TYPE
  6. API-OBJ-ID
  7. MAD-SEQ-NBR
  8. SEQ-NBR
KeyChange, SubsetWhere STATUS = 1MA64.3
MAGSET5
  1. API-OBJ-ID
  2. MAD-SEQ-NBR
  3. SEQ-NBR
AP20.1, AP20.2, AP20.3, AP20.4, AP20.5, AP20.7, AP21.1, AP23.1 +22 more (list truncated in source)
MAGSET6
  1. COMPANY
  2. AUTH-CODE
  3. VENDOR
  4. INVOICE
  5. SUFFIX
  6. CANCEL-SEQ
  7. SEQ-NBR
KeyChange, SubsetWhere STATUS = 1MA64.1
MAGSET7
  1. COMPANY
  2. STATUS
  3. OPERATOR
  4. MSG-ORIGIN
  5. CREATE-DATE
  6. RESPOND-DATE
  7. VENDOR
  8. API-OBJ-ID
  9. MAD-SEQ-NBR
  10. SEQ-NBR
KeyChangeMA264
MAGSET8
  1. COMPANY
  2. STATUS
  3. AUTH-CODE
  4. MSG-ORIGIN
  5. CREATE-DATE
  6. RESPOND-DATE
  7. VENDOR
  8. API-OBJ-ID
  9. MAD-SEQ-NBR
  10. SEQ-NBR
KeyChangeMA264
MAGSET9
  1. COMPANY
  2. AUTH-CODE
  3. VEN-ITEM
  4. VAR-TYPE
  5. TYPE
  6. API-OBJ-ID
  7. MAD-SEQ-NBR
  8. SEQ-NBR
SubsetWhere STATUS = 1MA64.3

Relations

Relationship map — 1:1 lookups/parents on the left, 1:M children on the right (up to 14 each)
POMATCHOBJMAINVMSG

One to many (1) — child tables

RelationTableRulesConditionField map
PomatchobjPOMATCHOBJ
MAG-COMPANY→PMJ-COMPANY
MAG-PO-NUMBER→PMJ-PO-NUMBER
MAG-PO-RELEASE→PMJ-PO-RELEASE
MAG-PO-CODE→PMJ-PO-CODE
MAG-PO-LINE-NBR→PMJ-LINE-NBR
—→PMJ-TRAN-DATE
—→PMJ-TRAN-TIME
—→PMJ-MATCH-OBJ-ID
—→PMJ-MATCH-SEQ-NBR
—→PMJ-TYPE

Programs

Updated by (34)

Referenced by (14)