F1640F1602SequencingActivities

F1640, F1602 Sequencing Activities

Minor Business Rule

Object Name: B1600200

Parent DLL: CFIN

Location: Client/Server

Language: C

Business Function Specification

Source NameB16002020DesignerAnna Kyazyan

Data Structure D1600200ProgrammerAnna Knyazyan

Function NameF1640, F1602 Sequencing Activities

System Code16

Function CategoryTransaction Function

Function Use




Revisions Log 

DateModifications bySAR NumberDescription

02/23/99Anna Knyazyan2631164Created

03/12/99Anna Knyazyan2466234Validated Input 

Parameters and added error message


1.Functional Description


1.1Purpose

This business function is used to load the cache with F1640 records with the summarized activity 

costs and to retrieve the specified records from the cache or to retrieve the rolled up activity costs 

only.  The function is called from R1640 (UBE) and P1641.  The function opens the table F1640 and loads 

all records into the cache.  While records are loaded B1600200.c calls B1600230.c to get summarized 

activity costs based on user specified parameters (View Number, Fiscal Year, Ledger Type, Period From and 

Period Thru).  Then based on processing option or the flag defining multi-level or single level, the 

function retrieves the records from the cache.


1.2Setup Notes and Prerequisites



1.2Special Logic


Processing option or the flag defines the sequence of records retrieved from the cache:

If multi-level and no selection - retrieves all records in parent/child sequence

If multi-level and selection - retrieves all children of selected (or specified) activity or 

activities

If single level (with and without selection)- retrieves the rolled up activity costs 


Before calling B1600190.c and loading the cache, the records in F1640 are sequenced in ascending 

order of Level Code.  Also Index is created for each activity read from the table which is used in 

creating MultiLevelIndex (second index of the cache) in B1600190.c.



2.Technical Specifications



2.1Parameters:

Data Item Data Structure DescriptionI/ORequiredNotes

JOBSJob NumberIY

GENLNGID CursorIY


MODEProcessing ModeIY'1' = Fetch first record 

'2' = Add to cache 

'6' = Get next record 

'7' = Add and Update 

'8' = Terminate cache 


ACTBActivity CodeI/OYTo retrieve records from cache


EV01FlagMultiLevelIYTo sequence in single/multi level: 

'0' or blank = single level 

'1' = multi level 


EV01Valid FlagIYTo retrieve single record, group of records, or 

all records: 

'0' = single record 

FlagMultiLevel = '1' and 

'1' = all records in multi level, or 

'2' = group of records in multi level


PARAParent LevelI/OYRequired only in case of retrieving a group of 

records


VWNMView NumberIYRequired to access B1600230.c to get summarized 

activity costs


CFYCentury/Fiscal YearIYRequired to access B1600230.c to get summarized 

activity costs


LTLedger TypeIYRequired to access B1600230.c to get summarized 

activity costs


EV01Cache Code ErrorIYUsed to check the status of requested actions: 

'0' Process Successful 

'1' Reached end of CACHE Data Set 

'2' Invalid Input Parameter 

'3' Failed to Create CACHE 

'4' Failed to Add CACHE 

'5' Failed to Delete CACHE 

'6' The record is not in the cache or cache is empty 

'7' Failed to Update CACHE 

'8' Fetch from Cache failed 

'9' Reached end of the group




2.2Related Tables 

Table Table Description

F1640Activity Master File



2.3Related Business Functions

Source NameFunction Name

B1600230Cost Object Inquiry Total Amounts

B1600190Cache Total Costs Calculation Per Group


2.4Processing 


If View Number and Century/Fiscal Year are not equal to 0 then

If Process Mode is not equal to '0'

And Cache Code Error is equal to '0'

Call internal function Retrieve from Cache

If Cache Code Error is equal to '6' then

Open table F1640

Call internal function Load Cache

In Load Cache function

For every activity in F1640 call B1600230 to get summarized cost based on

View Number, Century/Fiscal Year, Ledger Type, Period From and Period Thru

After getting the cost call B1600190 to load the cache:

If summarized activity cost is equal to 0 then

Call B1600190 with Process Mode = 2

Else

Call B1600190 with Process Mode = 7

If Load Cache function returns successfully then

Retrieves the record from cache


Note:  Must identify how records should read from cache (single, all records in multilevel, group of 

records in multileve^

Data Structure

D1600200 - F1640, F1602 Sequencing Activities

Parameter NameData ItemData TypeReq/OptI/O/Both
szActivityCode_ACTBACTBcharOPTNONE

The aggregation of actions performed within an organization that are useful for purposes of activity-based costing.

szParentActivityCode_PARAPARAcharOPTNONE

 Identifies the parent of an activity. It is the mechanism used to establish activity hierarchies.

mnLevelCode_LLXLLXMATH_NUMERICOPTNONE

This identifies the lowest level in any bill of material at which a particular component may appear..

cActivityGroup_ACGRACGRcharOPTNONE

This field indicates whether this entry in the Activity Master is a single activity or a group of activities, such as subprocesses.

mnOriginalPosting_MATH01MATH01MATH_NUMERICOPTNONE

- - - Good Performance Low Value. 

mnViewNumber_VWNMVWNMMATH_NUMERICOPTNONE

A number from 1 to 10 that specifies how the system posts records from the Account Ledger table (F0911) to the Cost Analyzer Balances 
table (F1602). This number also specifies which managerial accounting posting code (PM01 - PM10) in the F0911 table to update as 
posted. For example, if the view number is 1, then the system updates PM01 with a P when the F0911 record is marked as being posted.

mnCenturyFiscalYear_CFYCFYMATH_NUMERICOPTNONE

A field used to store the century concatenated with the fiscal year.

szLedgerType_LTLTcharOPTNONE

A user defined code (09/LT) that specifies the type of ledger, such as AA (Actual Amounts), BA (Budget Amount), or AU (Actual Units). You 
can set up multiple, concurrent accounting ledgers within the general ledger to establish an audit trail for all transactions.

szAccountId_AIDAIDcharOPTNONE

A number that the system assigns to each general ledger account in the Account Master table (F0901) to uniquely identify it. 

szBusinessUnit_MCUMCUcharOPTNONE

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.

cFlagMultiLevel_EV01EV01charOPTNONE

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

cFlagOriginalPosting_EV01EV01charOPTNONE

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

mnPeriodFrom_PNPNMATH_NUMERICOPTNONE

A number indicating the current accounting period.  This number, used in conjunction with the Company Constants table (F0010) and the 
General Constants table (F0009), allows the user to define up to 14 accounting periods. See General Ledger Date.  The current period number 
is used to determine posted before and posted after cut off warning messages.  It is also used as the default accounting period in the 
preparation of financial reports.

mnPeriodThru_PNPNMATH_NUMERICOPTNONE

A number indicating the current accounting period.  This number, used in conjunction with the Company Constants table (F0010) and the 
General Constants table (F0009), allows the user to define up to 14 accounting periods. See General Ledger Date.  The current period number 
is used to determine posted before and posted after cut off warning messages.  It is also used as the default accounting period in the 
preparation of financial reports.

cProcessMode_MODEMODEcharOPTNONE

The processing mode used in Purchase Order Consolidator to signify when specific orders are being processed.

mnJobNumber_JOBSJOBSMATH_NUMERICOPTNONE

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

cValidFlag_EV01EV01charOPTNONE

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

cCacheCodeError_EV01EV01charOPTNONE

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

szErrorMessageID_DTAIDTAIcharOPTNONE

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.

cSuppressErrorMessages_SUPPSSUPPScharOPTNONE

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.

mnEndingPosting_MATH01MATH01MATH_NUMERICOPTNONE

- - - Good Performance Low Value. 

szCostObject1_ABR1ABR1charOPTNONE

A cost object code, such as an equipment item number or an address book number. If you enter a cost object code, you must also specify 
the cost object type. This field functions the same and is validated the same as the subledger field, but the system does not post the data in 
the cost object code field to the Account Balances file (F0902).

cCostObjectType1_ABT1ABT1charOPTNONE

A code that specifies the type of cost object and the type of editing. Valid types are stored in the Cost Object Types table (F1620) and can 
be added or modified using the Cost Object Types program (P1620).

szCostObject2_ABR2ABR2charOPTNONE

A cost object code, such as an equipment item number or an address book number. If you enter a cost object code, you must also specify 
the cost object type. This field functions the same and is validated the same as the subledger field, but the system does not post the data in 
the cost object code field to the Account Balances file (F0902).

cCostObjectType2_ABT2ABT2charOPTNONE

A code that specifies the type of cost object and the type of editing. Valid types are stored in the Cost Object Types table (F1620) and can 
be added or modified using the Cost Object Types program (P1620).

szCostObject3_ABR3ABR3charOPTNONE

A cost object code, such as an equipment item number or an address book number. If you enter a cost object code, you must also specify 
the cost object type. This field functions the same and is validated the same as the subledger field, but the system does not post the data in 
the cost object code field to the Account Balances file (F0902).

cCostObjectType3_ABT3ABT3charOPTNONE

A code that specifies the type of cost object and the type of editing. Valid types are stored in the Cost Object Types table (F1620) and can 
be added or modified using the Cost Object Types program (P1620).

szSubledger_SBLSBLcharOPTNONE

A code that identifies a detailed, auxiliary account within a general ledger account. A subledger can be an equipment item number or an 
address book number. If you enter a subledger, you must also specify the subledger type.

cSubledgerType_SBLTSBLTcharOPTNONE

A user defined code (00/ST) that is used with the Subledger field to identify the subledger type and how the system performs subledger 
editing. On the User Defined Codes form, the second line of the description controls how the system performs editing. This is either hard-coded 
or user defined. Valid values include: A Alphanumeric field, do not edit   N Numeric field, right justify and zero fill   C Alphanumeric field, right 
justify and blank fill  

szMultiLevelIndex_S11S11charOPTNONE

User Defined Codes (10 separate codes are allowed) which can be used to generate selective reporting based on user assigned values 
of these codes.

mnActivityCost_MATH01MATH01MATH_NUMERICOPTNONE

- - - Good Performance Low Value. 

szDriverCode_DRCDDRCDcharOPTNONE

A code that identifies drivers within the Advanced Cost Accounting system.

cActivityAttribute1_ATR1ATR1charOPTNONE

One of five attributes used to identify specific characteristics of activities. For example, assign attributes that identify mission-related 
activities versus non-mission related activities. Attributes are user defined codes (system 16, types 6 through 10).

cActivityAttribute2_ATR2ATR2charOPTNONE

One of five attributes used to identify specific characteristics of activities. For example, assign attributes that identify mission-related 
activities versus non-mission related activities. Attributes are user defined codes (system 16, types 6 through 10).

cActivityAttribute3_ATR3ATR3charOPTNONE

One of five attributes used to identify specific characteristics of activities. For example, assign attributes that identify mission-related 
activities versus non-mission related activities. Attributes are user defined codes (system 16, types 6 through 10).

cActivityAttribute4_ATR4ATR4charOPTNONE

One of five attributes used to identify specific characteristics of activities. For example, assign attributes that identify mission-related 
activities versus non-mission related activities. Attributes are user defined codes (system 16, types 6 through 10).

cActivityAttribute5_ATR5ATR5charOPTNONE

One of five attributes used to identify specific characteristics of activities. For example, assign attributes that identify mission-related 
activities versus non-mission related activities. Attributes are user defined codes (system 16, types 6 through 10).

szCategoryCode1_ACC1ACC1charOPTNONE

One of five reporting codes that you can assign to an activity, process,subprocess, etc. Use these codes to classify activities for reporting 
based on specific characteristics. For example, assign codes that identify customer-related activities versus product-related activities. 
Category codes are user defined (system 16, types 11 through 15).

szCategoryCode2_ACC2ACC2charOPTNONE

One of five reporting codes that you can assign to an activity, process,subprocess, etc. Use these codes to classify activities for reporting 
based on specific characteristics. For example, assign codes that identify customer-related activities versus product-related activities. 
Category codes are user defined (system 16, types 11 through 15).

szCategoryCode3_ACC3ACC3charOPTNONE

One of five reporting codes that you can assign to an activity, process,subprocess, etc. Use these codes to classify activities for reporting 
based on specific characteristics. For example, assign codes that identify customer-related activities versus product-related activities. 
Category codes are user defined (system 16, types 11 through 15).

szCategoryCode4_ACC4ACC4charOPTNONE

One of five reporting codes that you can assign to an activity, process,subprocess, etc. Use these codes to classify activities for reporting 
based on specific characteristics. For example, assign codes that identify customer-related activities versus product-related activities. 
Category codes are user defined (system 16, types 11 through 15).

szCategoryCode5_ACC5ACC5charOPTNONE

One of five reporting codes that you can assign to an activity, process,subprocess, etc. Use these codes to classify activities for reporting 
based on specific characteristics. For example, assign codes that identify customer-related activities versus product-related activities. 
Category codes are user defined (system 16, types 11 through 15).

szACTBDescription_DL01DL01charOPTNONE

A user defined name or remark.

idCursor_GENLNGGENLNGIDOPTNONE

General purpose ID variable.

mnParentLevel_MATH01MATH01MATH_NUMERICOPTNONE

- - - Good Performance Low Value. 

szCostObject4_ABR4ABR4charOPTNONE

A cost object code, such as an equipment item number or an address book number. If you enter a cost object code, you must also specify 
the cost object type. This field functions the same and is validated the same as the subledger field, but the system does not post the data in 
the cost object code field to the Account Balances file (F0902).

cCostObjectType4_ABT4ABT4charOPTNONE

A code that specifies the type of cost object and the type of editing. Valid types are stored in the Cost Object Types table (F1620) and can 
be added or modified using the Cost Object Types program (P1620).

Related Functions

B1600190 Cache Total Costs Calculation Per Group

Related Tables

F1602 Cost Analyzer Balances
F1640 Activity Master File