F3007ResourceUnitsCacheFunction

F3007 Resource Units Cache

Minor Business Rule

Object Name: B3003830

Parent DLL: CMFGBASE

Location: Client/Server

Language: C

1.Functional Description

1.1Purpose
This function will perform Load, Delete, Update, Get, and Clear functions on the Resource Units Cache used in Resource Units Revisions.  On a Create 
process, an identifier for the cache (hCache handle) is passed back to the calling program for subsequent calls to this function.  


1.2Setup Notes and Prerequisites

The calling application is responsible for loading all appropriate key values to the data structure and identifying the number of keys to use in 
retrieval/update processes.  The application must also store the hCache pointers passed back from the "Create" process and pass these pointers back to the business 

function on the other process modes which require them (see technical specifications below).


1.3Special Logic

There is no special logic within this function.

2.Technical Specifications


2.4Processing 


I.    Perform setup functions 

A. Initialize cache to get handle.
B.Initialize return code to success.

C.If not successful, Set error "032E,"  "Error Processing Cache" and set return code to failure.


II.  Processing Based on Mode.


A.If Process Mode is "1" - GET:
1.Retrieve element from cache using keys to index.

B.If Process Mode is "2" - ADD:
1.(define logic for addition)

C.If Process Mode is "3" - UPDATE:
1. If element exist, update, else add element to cache.  

D.If Process Mode is "4" - DELETE:
1.(define logic for delete)  

E.If Process Mode is "5" - DELETE ALL:

1.(define logic for delete all).

F.If Process Mode is "6" - GET NEXT:
1.(define logic for get next).

G.If Process Mode is "7" - ADD/UPDATE:

1.(define logic for add/update).

H.If Process Mode is "8" - END
1.Perform cleanup functions (Terminate cache).
I.If Process Mode is "9" - END
1.Close the cursor.

Data Structure

D3003830 - F3007 Resource Units Cache

Parameter NameData ItemData TypeReq/OptI/O/Both
szBranchPlantMMCUcharOPTNONE

A code that represents a high-level business unit. Use this code to refer to a branch or plant that might have departments or jobs, which 
represent lower-level business units, subordinate to it. For example:     o Branch/Plant (MMCU)     o Dept A (MCU)     o Dept B (MCU)     o Job 123 
(MCU) Business unit security is based on the higher-level business unit.

szBusinessUnitMCUcharOPTNONE

An alphanumeric code that identifies a separate entity within a business for which you want to track costs. For example, a business unit 
might be a warehouse location, job, project, work center, branch, or plant. You can assign a business unit to a document, entity, or person for 
purposes of responsibility reporting. For example, the system provides reports of open accounts payable and accounts receivable by 
business unit to track equipment by responsible department. Business unit security might prevent you from viewing information about business units 
for which you have no authority.

mnCalendarYearYRMATH_NUMERICOPTNONE

The calendar year for this calendar.

mnCalendarMonthMTMATH_NUMERICOPTNONE

A number that corresponds to the month in a calendar year. 

cShiftCodeSHFTcharOPTNONE

A user defined code (00/SH) that identifies daily work shifts. In payroll systems, you can use a shift code to add a percentage or amount to 
the hourly rate on a timecard. For payroll and time entry: If an employee always works a shift for which a shift rate differential is applicable, 
enter that shift code on the employee's master record. When you enter the shift on the employee's master record, you do not need to enter the 
code on the timecard when you enter time. If an employee occasionally works a different shift, you enter the shift code on each applicable 
timecard to override the default value.

szUnitOfMeasureUMcharOPTNONE

A user defined code (00/UM) that identifies the unit of measurement for an amount or quantity. For example, it can represent a barrel, box, 
cubic meter, liter, hour, and so on.

szBusinessUnitTypeSTYLcharOPTNONE

A user defined code (00/MC) that identifies the classification of the business unit.

mnWorkCenterEfficiencyWOREMATH_NUMERICOPTNONE

A user defined value that indicates how efficiently a work center operates. This value usually refers to staff efficiency. When you enter a 
value in this field, and the Modify Cost by Work Center Efficiency field in the Job Shop Manufacturing Constants table (F3009) is set to Y, the 
system creates a new cost component (B4) from the cost calculated from the direct labor cost (B1). For example, if the constant is set to Y, the value 
of this field is 80%, and the direct labor cost is 10, the system creates a B4 cost component for 2 in the Item Cost Component Add-Ons table 
(F30026). The Refresh Resource Units program also uses this value as a default when calculating rated capacity. Enter percents as whole 
numbers. For example, enter 80% as 80.00. Note: The system expects that the routing times entered for each operator are the actual times it 
takes to complete an operation. Efficiency does not affect total cost. Efficiency does reassign some of the costs into different cost 
components. Efficiency does not change the duration or backscheduling of a work order.

mnWorkCenterUtilizationWORUMATH_NUMERICOPTNONE

A percentage that indicates how intensively a work center is being used. This value usually refers to machine use. It is the ratio of the direct 
time charged for production activities to the planned hours. The Refresh Resource Units program also uses this value as a default when 
calculating rated capacity. Enter percents as whole numbers. For example, enter 80% as 80.00.

mnResourceUnits001RU01MATH_NUMERICOPTNONE

A number that specifies a quantity that the system uses to calculate capacity. You can enter this number as units, currency, hours, floor 
space, or so on.

mnResourceUnits002RU02MATH_NUMERICOPTNONE

A number that specifies a quantity that the system uses to calculate capacity. You can enter this number as units, currency, hours, floor 
space, or so on.

mnResourceUnits003RU03MATH_NUMERICOPTNONE

A number that specifies a quantity that the system uses to calculate capacity. You can enter this number as units, currency, hours, floor 
space, or so on.

mnResourceUnits004RU04MATH_NUMERICOPTNONE

A number that specifies a quantity that the system uses to calculate capacity. You can enter this number as units, currency, hours, floor 
space, or so on.

mnResourceUnits005RU05MATH_NUMERICOPTNONE

A number that specifies a quantity that the system uses to calculate capacity. You can enter this number as units, currency, hours, floor 
space, or so on.

mnResourceUnits006RU06MATH_NUMERICOPTNONE

A number that specifies a quantity that the system uses to calculate capacity. You can enter this number as units, currency, hours, floor 
space, or so on.

mnResourceUnits007RU07MATH_NUMERICOPTNONE

A number that specifies a quantity that the system uses to calculate capacity. You can enter this number as units, currency, hours, floor 
space, or so on.

mnResourceUnits008RU08MATH_NUMERICOPTNONE

A number that specifies a quantity that the system uses to calculate capacity. You can enter this number as units, currency, hours, floor 
space, or so on.

mnResourceUnits009RU09MATH_NUMERICOPTNONE

A number that specifies a quantity that the system uses to calculate capacity. You can enter this number as units, currency, hours, floor 
space, or so on.

mnResourceUnits010RU10MATH_NUMERICOPTNONE

A number that specifies a quantity that the system uses to calculate capacity. You can enter this number as units, currency, hours, floor 
space, or so on.

mnResourceUnits011RU11MATH_NUMERICOPTNONE

A number that specifies a quantity that the system uses to calculate capacity. You can enter this number as units, currency, hours, floor 
space, or so on.

mnResourceUnits012RU12MATH_NUMERICOPTNONE

A number that specifies a quantity that the system uses to calculate capacity. You can enter this number as units, currency, hours, floor 
space, or so on.

mnResourceUnits013RU13MATH_NUMERICOPTNONE

A number that specifies a quantity that the system uses to calculate capacity. You can enter this number as units, currency, hours, floor 
space, or so on.

mnResourceUnits014RU14MATH_NUMERICOPTNONE

A number that specifies a quantity that the system uses to calculate capacity. You can enter this number as units, currency, hours, floor 
space, or so on.

mnResourceUnits015RU15MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits016RU16MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits017RU17MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits018RU18MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits019RU19MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits020RU20MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits021RU21MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits022RU22MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits023RU23MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits024RU24MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits025RU25MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits026RU26MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits027RU27MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits028RU28MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits029RU29MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits030RU30MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

mnResourceUnits031RU31MATH_NUMERICOPTNONE

A value expressed in units, dollars, hours, floor space, etc., that is used to calculate capacity.

szProgramIdPIDcharOPTNONE

The number that identifies the batch or interactive program (batch or interactive object). For example, the number of the Sales Order Entry 
interactive program is P4210, and the number of the Print Invoices batch process report is R42565. The program ID is a variable length value. 
It is assigned according to a structured syntax in the form TSSXXX, where: T The first character of the number is alphabetic and identifies the 
type, such as P for Program, R for Report, and so on. For example, the value P in the number P4210 indicates that the object is a 
program. SS The second and third characters of the number are numeric and identify the system code. For example, the value 42 in the number P4210 
indicates that this program belongs to system 42, which is the Sales Order Processing system. XXX The remaining characters of the numer are 
numeric and identify a unique program or report. For example, the value 10 in the number P4210 indicates that this is the Sales Order Entry 
program.

szWorkStationIdJOBNcharOPTNONE

The code that identifies the work station ID that executed a particular job.

szUserIdUSERcharOPTNONE

The code that identifies a user profile.

jdDateUpdatedUPMJJDEDATEOPTNONE

The date that specifies the last update to the file record.

mnTimeOfDayTDAYMATH_NUMERICOPTNONE

The computer clock in hours:minutes:seconds.

nNumberOfKeysINT01integerOPTNONE

Number of Days in Future to Query for Responses Due. 

cProcessModeEV01charOPTNONE

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

cCacheCodeErrorEV01charOPTNONE

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

cSuppressErrorMessageEV01charOPTNONE

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

szErrorMessageIDDTAIcharOPTNONE

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.

idCursorGENLNGIDOPTNONE

General purpose ID variable.

cReturnCursorEV01charOPTNONE

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

mnJobNumberJOBSMATH_NUMERICOPTNONE

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

Related Functions

None

Related Tables

None