CacheProcessFlexInventoryAcctng

Cache, Process Flex Inventory Accounting

Major Business Rule

Object Name: B4101090

Parent DLL: COPBASE

Location: Client/Server

Language: C

Functional Description

Purpose

This function is used to maintain Flex Inventory Accounting CACHE.

This cache is used by the Inventory Master Business Function process to pass Inventory fields to the

"Build Flexible Account" Business Function.  

You can use this function to add, change, inquire, and delete cache records.  The records will be

keyed by Job Number since there will only be on Inventory detail record passed thru the process

at a time.


Setup Notes and Prerequisites


Special Logic


Technical Specification


Parameters

Data Item     Data Structure Description      I/O      Required     Notes

SUPPS         Suppress Error Message           I          N

DTAI          Error Message ID                 O          N

EV01          Action                           I          Y

JOBS          Job Number                       I          Y

ITM           Short Item Number                B          N         F4102 Key

MCU           Branch/Plant                     B          N         F4102 Key/F0006 Key/F4111 Key

AN8           Address Number                   B          N         F4102 Key

ITM           Item Number                      B          N         F4102 Key

LITM          Second Item Number               B          N         F4111 field current record

AITM          Third Item Number                B          N         F4111 field current record

KIT           Parent Item Number               N          N         F4111 field current record

MMCU          Branch                           B          N         F4111 field current record

DMCT          Agreement Number - Distribution  B          N         F41ll field current record

DOCO          Document Number                  B          N         F4111 field current record

TREF          Transaction Reference            B          N         F4111 field current record

RCD           Reason Code                      B          N         F4111 field current reocrd


Related Tables


Related Business Fuctions


Processing

You call call this business function with four different actions (EV01):

1 = Retrive

2 = Add

3 = Update

4 = Delete

8 = Terminate CACHE


If the Action Code(EV01) = '1'(Retrieve), fetch a record from the cache (using JOBS - Job Number as

the key).  If error, return "Action Invalid"(0001) error message.


If the Action Code(EV01) = '2'(Add), add a record to the cache with all the F4111 database fields 

from

the passed parameters (using JOBS - Job Number as the key).  If error, return "Action Invalid"(0001)

error message.


If the Action Code(EV01) = '3'(Update), fetch a record from the cache (using JOBS - Job Number as the

key) and update the record in the cache with all the database fields from the passed parameters.

If error, return "Action Invalid"(0001) error message.


If the Action Code(EV01) = '4'(Delete), delete all matching records from the cache (using JOBS - Job

Number as the key). If error, return "Action Invalid"(0001) error message.


If the Action Code(EV01) = '8'(Terminate), terminate CACHE from memory (using JOBS - Job Number as 

the

key). If error, return "Action Invalid"(0001) error message. 

 




Data Structure

D4101090 - Cache, Process Flex Inventory Acounting

Parameters
Data Item     Data Structure Description      I/O      Required     Notes
SUPPS         Suppress Error Message           I          N
DTAI          Error Message ID                 O          N

EV01          Action                           I          Y

JOBS          Job Number                       I          Y

ITM           Short Item Number                B          N         F4102 Key

MCU           Branch/Plant                     B          N         F4102 Key/F0006 Key/F4111 Key

AN8           Address Number                   B          N         F4102 Key

ITM           Item Number                      B          N         F4102 Key

LITM          Second Item Number               B          N         F4111 field current record

AITM          Third Item Number                B          N         F4111 field current record

KIT           Parent Item Number               N          N         F4111 field current record

MMCU          Branch                           B          N         F4111 field current record

DMCT          Agreement Number - Distribution  B          N         F41ll field current record

DOCO          Document Number                  B          N         F4111 field current record

TREF          Transaction Reference            B          N         F4111 field current record

RCD           Reason Code                      B          N         F4111 field current reocrd



^

Parameter NameData ItemData TypeReq/OptI/O/Both
cSuppressErrorMessageSUPPScharNONENONE

A flag indicating whether or not runtime error messaging will occur when an error message is issued from a business function.        0 = allow 
runtime error message handling.        1 = suppress runtime error message handling.

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.

cActionCodeACTNcharNONENONE

A code that specifies the action that is performed. Valid values are: A Add C Change

mnJobNumberJOBSMATH_NUMERICNONENONE

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

mnShortItemNumberITMMATH_NUMERICNONENONE

Parameters
Data Item     Data Structure Description      I/O      Required     Notes
ITM           Short Item Number                B          N         F4102 Key

^

szBranchPlantMCUcharNONENONE

Parameters
Data Item     Data Structure Description      I/O      Required     Notes
MCU           Branch/Plant                     B          N         F4102 Key/F0006 Key/F4111 Key

^

mnAddressNumberAN8MATH_NUMERICNONENONE

Parameters
Data Item     Data Structure Description      I/O      Required     Notes
AN8           Address Number                   B          N         F4102 Key


^

sz2ndItemNumberLITMcharNONENONE

Parameters
Data Item     Data Structure Description      I/O      Required     Notes
LITM          Second Item Number               B          N         F4111 field current record

^

sz3rdItemNumberAITMcharNONENONE

Parameters
Data Item     Data Structure Description      I/O      Required     Notes
AITM          Third Item Number                B          N         F4111 field current record

^

mnKitItemNumberKITMATH_NUMERICNONENONE

Parameters
Data Item     Data Structure Description      I/O      Required     Notes
KIT           Parent Item Number               N          N         F4111 field current record


^

szBranchMMCUcharNONENONE

Parameters
Data Item     Data Structure Description      I/O      Required     Notes
MMCU          Branch                           B          N         F4111 field current record

^

szAgreementNumberDMCTcharNONENONE

Parameters
Data Item     Data Structure Description      I/O      Required     Notes
DMCT          Agreement Number - Distribution  B          N         F41ll field current record

^

mnOrderNumberDOCOMATH_NUMERICNONENONE

Parameters
Data Item     Data Structure Description      I/O      Required     Notes
DOCO          Document Number                  B          N         F4111 field current record

^

szTransactionReferenceTREFcharNONENONE

Parameters
Data Item     Data Structure Description      I/O      Required     Notes
TREF          Transaction Reference            B          N         F4111 field current record


^

szReasonCodeRCDcharNONENONE

Parameters
Data Item     Data Structure Description      I/O      Required     Notes
RCD           Reason Code                      B          N         F4111 field current reocrd



^

Related Functions

None

Related Tables

None