F4111UpdateParentLotAssociations

F4111 Update Parent Lot Associations

Minor Business Rule

Object Name: N3101400

Parent DLL: CMFGBASE

Location: Client/Server

Language: NER

1.Functional Description

1.1Purpose
This function will update the Parent Lot number on the Item Ledger (F4111) table from the 
associations assigned in the Serial Number Associations application (P3107).  

• Serialized components which are being "de-associated" from the previously assigned parent lot are 
stored in the LSN Deletion cache updated in P3107.  This cache is processed first.  The F4111 records 

with the matching Item Number (ITM), Branch/Plant (MCU), Location (LOCN), Lot Number (LOTN), Parent Item 

(KIT), Parent Branch/Plant (MMCU), Parent Location (LOCN), and Parent Lot (PLOT) will have the Parent 

Lot changed to spaces if the Program Id on the Item Ledger record. is "P31123" (R31123), "P31113", or 

"P31420" (R31420).

• After deletions are process, the new associations are updated on the Item Ledger table (F4111). All 
records on the associations cache (with an "Associated" status) are processed.  The F4111 records with 

the matching Item Number (ITM), Branch/Plant (MCU), Location (LOCN), Lot Number (LOTN), Parent Item 

(KIT), Parent Branch/Plant (MMCU), Parent Location (LOCN), and Parent Lot (PLOT) will have the Parent 

Lot changed to spaces if the Program Id on the Item Ledger record. is "P31123" (R31123), "P31113", or 

"P31420" (R31420).



1.3Special Logic
None.

2.Technical Specifications
2.4Processing 

Process "Deletes":


1)Read the LSN Deletion cache sequentially; for each record read:

a)Retrieve all records from the Item Ledger table (F4111) matching the following values from the 
"Deletion"  cache record:

i)LOTN  Component Lot Number
ii)ITM  Component Item Number

iii)MCU  Component Branch/Plant

iv)PLOT  Parent Lot Number

v)ITM  Parent Item Number

vi)MMCU  Parent Branch/Plant


b)For each record retrieved from the F4111 table:
i)Skip records unless the Program Id is "P31123" ("R31123"), "P31113", "P31420" ("R31420").
ii)Skip records if the Component Item Number = Parent Item Number.

iii)Skip records if the Order Number (DOCO) does not match the Order Number passed in as 

input.


c)For each record selected from the F4111 table, space out the Parent Lot number and update the 
record.



Process "Associations":


2)Read the Parent LSN cache sequentially; skip records which do not have a status of "A" (i.e. 
"Associated").  For each cache record selected:


a)Read LSN Association cache sequentially for the Sequence Number retrieved from the Parent Cache 
record.  For each record selected:

i)Retrieve all records from the Item Ledger table (F4111) matching the following values from 
the "Association"  cache record:

(1)LOTN  Component Lot Number
(2)ITM  Component Item Number

(3)MCU  Component Branch/Plant


b)For each record retrieved from the F4111 table:
i)Skip records unless the Program Id is "P31123" ("R31123"), "P31113", "P31420" ("R31420").
ii)Skip records if the Component Item Number = Parent Item Number.

iii)Skip records if the Order Number (DOCO) does not match the Order Number passed in as 

input.


iv)For each record selected from the F4111 table, update the Parent Lot number from the value on 

the Parent LSN Cache record and audit information (TDAY, USER, UPMJ, JOB)'85.."P31114"


Data Structure

D3101400 - F4111 Update Parent Lot Associations

Parameter NameData ItemData TypeReq/OptI/O/Both
mnDocumentOrderInvoiceEDOCOMATH_NUMERICNONENONE

A number that identifies an original document. This document can be a voucher, a sales order, an invoice, unapplied cash, a journal entry, 
and so on.

mnDeletionCacheJobJOBSMATH_NUMERICNONENONE

The job number (work station ID) which executed the particular job.

mnParentCacheJobJOBSMATH_NUMERICNONENONE

The job number (work station ID) which executed the particular job.

mnAssocCacheJobJOBSMATH_NUMERICNONENONE

The job number (work station ID) which executed the particular job.

cSuppressErrorMsgsEV01charNONENONE

An option that specifies the type of processing for an event.

szErrorMessageIDDTAIcharNONENONE

A code that identifies and defines a unit of information. It is an alphanumeric code up to 8 characters long that does not allow blanks or 
special characters such as %, &, or +. You create new data items using system codes 55-59. You cannot change the alias.

Related Functions

None

Related Tables

None