APBATCH – Batch

System
Accounts Payable (AP)
Prefix
APB
Primary key
COMPANY, BATCH-NUM
Fields
15
Updated by
33 programs
Referenced by
3 programs

APBATCH is the Batch table in Lawson Accounts Payable (prefix APB). It is indexed by COMPANY, BATCH-NUM (APBSET1). It is related 1:1 to APCOMPANY and 1:M to APINVOICE and POMESSAGE. It is updated by AP125, AP126, AP170, AP20.1, AP20.2, AP20.3, AP20.4, AP20.5 and 25 more and referenced by AP00.4, AP220 and MA540. The table has 15 fields, 1 index and 4 documented relations.

About APBATCH

The Batch file contains unreleased invoice batches. This file is used only by companies that have the batch invoice entry option selected. A batch is a unique numeric value within a company for a group of unreleased invoices. Batch numbers are automatically assigned by the system or entered manually depending on the batch entry options selected for the company.

Fields (15)

Column = COBOL field name without the APB- prefix, hyphens → underscores. Derived fields are computed by the application and are not stored.

Field / columnTypeDescription & valuesUpdated by
APB-COMPANY PK
COMPANY
Numeric 4The company number. Must be a valid record in the Accounts Payable Company file.AP170, AP25.1, AP25.2, API1.1, API2.1
APB-BATCH-NUM PK
BATCH_NUM
Numeric 6The batch number. This number is system-assigned or user-assigned depending on the option selected for the company in the Auto Batch Numbering field.AP170, AP25.1, AP25.2, API1.1, API2.1
APB-BATCH-DATE
BATCH_DATE
Numeric 8 (yyyymmdd)The system date the batch was created.AP170, AP25.1, API1.1, API2.1
APB-DISTRIB-DATE
DISTRIB_DATE
Numeric 8 (yyyymmdd)The general ledger posting date assigned to the batch. Used to default a post date to all invoices entered for the batch.AP170, AP25.1, API1.1, API2.1
APB-CTL-NET-TOT
CTL_NET_TOT
Signed 18.2The control net total of all invoices, debit memos, and credit memos in the batch.AP125, AP126, AP25.1, AP25.2, AP26.1, AP27.1, API1.1, API2.1
APB-CTL-NBR-INV
CTL_NBR_INV
Numeric 15The control total number of invoices, debit memos, and credit memos in the batch.AP125, AP126, AP25.1, AP25.2, AP26.1, AP27.1, API1.1, API2.1
APB-CTL-VEND-HASH
CTL_VEND_HASH
Numeric 15The control total sum of all vendor numbers in the batch. Used with numeric vendor numbering only.AP125, AP126, AP25.1, AP25.2, AP26.1, AP27.1, API1.1, API2.1
APB-ACT-INV-TOT
ACT_INV_TOT
Signed 18.2The actual net total of all invoices entered for the batch.AP125, AP126, AP20.1, AP20.2, AP20.3, AP20.4, AP20.5, AP20.6 +23 more
APB-ACT-DB-TOT
ACT_DB_TOT
Signed 18.2The actual net total of all debit memos entered for the batch.AP125, AP126, AP20.1, AP20.2, AP20.3, AP20.4, AP20.5, AP20.7 +20 more
APB-ACT-CR-TOT
ACT_CR_TOT
Signed 18.2The actual net total of all credit memos entered for the batch.AP125, AP126, AP20.1, AP20.2, AP20.3, AP20.4, AP20.5, AP20.7 +20 more
APB-ACT-NBR-INV
ACT_NBR_INV
Numeric 15The actual total number of invoices entered for the batch.AP125, AP126, AP170, AP20.1, AP20.2, AP20.3, AP20.4, AP20.5 +21 more
APB-ACT-VEND-HASH
ACT_VEND_HASH
Numeric 15The actual total sum of vendor numbers entered for the batch. Used with numeric vendor numbering only.AP125, AP126, AP170, AP20.1, AP20.2, AP20.3, AP20.4, AP20.5 +24 more
APB-INV-CURRENCY
INV_CURRENCY
Alpha 5The currency code assigned to the batch. If assigned, the batch is restricted to invoices, debit memos, and credit memos with the currency selected. If left blank, invoice currency is not restricted for the batch. Must be a valid record in the Currency Code file.AP25.1, API1.1, API2.1
APB-ORIGIN-CODE
ORIGIN_CODE
Alpha 2Indicates the system the batch was created in. Must be a valid record in the General Ledger Codes file. Valid values are:
  • AP Lawson Accounts Payable system.
  • PO Lawson Purchase Order system.
AP25.1, API1.1, API2.1
APB-ACT-NET-AMT
ACT_NET_AMT
DerivedThe actual net amount of invoices, debit memos, and credit memos entered for the batch.

Indexes (1)

Keys marked * are descending. Every documented Lawson index is unique unless flagged Duplicates; Subset indexes carry a Where condition.

IndexKeysFlagsConditionUsed in
APBSET1COMPANY, BATCH-NUMPrimaryAP00.4, AP125, AP126, AP170, AP20.1, AP20.2, AP20.3, AP20.4 +22 more (list truncated in source)

Relations

One to one (1) — lookups and parents

RelationTableRulesConditionField map
ApcompanyAPCOMPANYRequiredAPB-COMPANYCPY-COMPANY

One to many (3) — child tables

RelationTableRulesConditionField map
ApibatchAPINVOICEDelete CascadesZeroesAPI-REC-STATUS, APB-COMPANYAPI-COMPANY, APB-BATCH-NUMAPI-BATCH-NUM, API-AUTH-CODE, API-OPERATOR, API-CREATE-DATE, API-CREATION-TIME, API-VENDOR, API-INVOICE, API-SUFFIX, API-CANCEL-SEQ
ApinvoiceAPINVOICEDelete CascadesZeroesAPI-REC-STATUS, APB-COMPANYAPI-COMPANY, APB-BATCH-NUMAPI-BATCH-NUM, API-AUTH-CODE, API-OPERATOR, API-CREATE-DATE, API-CREATION-TIME, API-VENDOR, API-INVOICE, API-SUFFIX, API-CANCEL-SEQ
PomessagePOMESSAGEAPB-COMPANYPOM-COMPANY, APB-BATCH-NUMPOM-BATCH-NBR, POM-VENDOR, POM-INVOICE, POM-SUFFIX, POM-PO-NUMBER, POM-PO-RELEASE, POM-LINE-NBR

Programs

Updated by (33)

Referenced by (3)