PACOST – Course Cost

System
Personnel (PA)
Prefix
CST
Primary key
COURSE, COST-TYPE, COST-CAT, EFFECTIVE-DATE
Fields
16
Updated by
2 programs
Referenced by
2 programs

PACOST is the Course Cost table in Lawson Personnel (prefix CST). It is indexed by COURSE, COST-TYPE, COST-CAT, EFFECTIVE-DATE (CSTSET1). It is related 1:1 to GLMASTER, CUCODES and PCODES and 1:M to PACOURSE. It is updated by TR01.1 and TR10.1 and referenced by TR201 and TR210. The table has 16 fields, 1 index and 6 documented relations.

About PACOST

Contains cost and account reference information for each course. TR10.1 (Course Costs) is the primary program that updates this file.

Fields (16)

Column = COBOL field name without the CST- 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
#CST-COURSE PK
COURSE
Alpha 10Contains the course code.TR10.1
#CST-COST-TYPE PK
COST_TYPE
Alpha 10Contains the specific cost classification.TR10.1
#CST-COST-CAT PK
COST_CAT
Alpha 10Contains the general cost classification.TR10.1
#CST-EFFECTIVE-DATE PK
EFFECTIVE_DATE
Numeric 8 (yyyymmdd)Contains the date the cost becomes effective. The course start date defaults.TR10.1
#CST-END-DATE
END_DATE
Numeric 8 (yyyymmdd)Contains the date the cost ends.TR10.1
#CST-COST
COST
Signed 11.2Contains the amount of the cost.TR10.1
#CST-DIST-COMPANY
DIST_COMPANY
Numeric 4Contains the distribution company for the cost.TR10.1
#CST-DST-ACCT-UNIT
DST_ACCT_UNIT
Alpha 15Contains the general ledger accounting unit to which the amount could be posted.TR10.1
#CST-DST-ACCOUNT
DST_ACCOUNT
Numeric 6Contains the general ledger account to which the amount could be posted.TR10.1
#CST-DST-SUB-ACCT
DST_SUB_ACCT
Numeric 4Contains the general ledger subaccount to which the amount could be posted.TR10.1
#CST-COST-DESIGNATR
COST_DESIGNATR
Alpha 1Indicates whether the cost is actual or budgeted.
  • A Actual
  • B Budget
TR10.1
#CST-CURRENCY-CODE
CURRENCY_CODE
Alpha 5Contains the currency in which the cost is recorded.TR10.1
#CST-CURR-ND
CURR_ND
Numeric 1The number of decimals assigned to a particular account as determined by the account currency.TR10.1
#CST-BASE-CURRENCY
BASE_CURRENCY
Alpha 5Contains the training system's base currency.TR10.1
#CST-BASE-ND
BASE_ND
Numeric 1The number of decimal positions defined for the training system's base currency.TR10.1
#CST-BASE-AMOUNT
BASE_AMOUNT
Signed 15.2Contains the cost in the training system's base currency.TR10.1

Indexes (1)

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
CSTSET1
  1. COURSE
  2. COST-TYPE
  3. COST-CAT
  4. EFFECTIVE-DATE
PrimaryTR01.1, TR10.1, TR201, TR210

Relations

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

One to one (5) — lookups and parents

RelationTableRulesConditionField map
AccountsGLMASTERRequiredWhen (CST-DIST-COMPANY != Zeroes) And (CST-DST-ACCT-UNIT != Spaces) And (CST-DST-ACCOUNT != Zeroes)
CST-DIST-COMPANY→GLM-COMPANY
CST-DST-ACCT-UNIT→GLM-ACCT-UNIT
CST-DST-ACCOUNT→GLM-ACCOUNT
CST-DST-SUB-ACCT→GLM-SUB-ACCOUNT
Base CurrencyCUCODESRequiredWhen CST-CURRENCY-CODE != Spaces
CST-BASE-CURRENCY→CUC-CURRENCY-CODE
CategoryPCODESRequiredWhen CST-COST-CAT != Spaces
"MC"→PCO-TYPE
CST-COST-CAT→PCO-CODE
CurrencyCUCODESRequiredWhen CST-CURRENCY-CODE != Spaces
CST-CURRENCY-CODE→CUC-CURRENCY-CODE
TypePCODESRequiredWhen CST-COST-TYPE != Spaces
"MT"→PCO-TYPE
CST-COST-TYPE→PCO-CODE

One to many (1) — child tables

RelationTableRulesConditionField map
CoursePACOURSERequired
CST-COURSE→CRS-COURSE
—→CRS-EFFECTIVE-DATE

Programs

Updated by (2)

Referenced by (2)