Defining Data Retrieval Elements

This chapter provides an overview of data retrieval elements, and discusses how to:

Click to jump to parent topicUnderstanding Data Retrieval Elements

In Global Payroll, you use data retrieval elements to retrieve data from the system.

There are six data retrieval elements included in the system:

PeopleSoft defines and delivers system elements; you name and define the basic parameters of other elements, such as arrays and brackets.

Batch Processing

During processing, the system truncates data that is retrieved by system elements and arrays when the data exceeds these lengths:

Character fields: 30

Numeric fields: 12.6

See Also

Defining Element Names

Click to jump to parent topicWorking with System Elements

This section provides overviews of system elements and batch processing of system elements, and discusses how to:

Click to jump to top of pageClick to jump to parent topicUnderstanding System Elements

System elements are delivered and maintained by PeopleSoft and usually contain payee-related data for use in calculations. Although you cannot add system elements, you have the ability to define and alter various parameters that control their use.

There are two types of system elements:

Note. To store the value of a database system element for reporting purposes, include the element in your process.

Click to jump to top of pageClick to jump to parent topicUnderstanding Batch Processing of System Elements

All system elements, whether they are database or system-computed elements, have several important considerations. A system element that is frequency controlled by compensatory rate, which is controlled by compensatory frequency, is annualized by the Frequency field and then deannualized, based on the calendar frequency. Thus, any element, such as earnings, deductions, or absences, that uses the Frequency field should be defined as having a frequency equal to the use calendar period frequency. This approach ensures correct results, avoiding additional annualization or deannualization.

Database System Elements

For database elements from effective-dated records, the row selected is based on context. Typically the value is as of the segment end date. If referenced during resolution of a sliced element, the value is as of the slice end date. When retrieving values from job records, for example, the system matches on employee ID, employee record, and the segment and slice end date.

System element definitions for the country being processed and those used by all countries are loaded at the beginning of a run. System elements are resolved when used in the process.

Note. Only database system elements that are used and have been defined as Store = Yes are stored in the result tables.

PeopleSoft HR Database System Element Records

The following table lists the database tables that populate database system elements:

Table Name

Description

PERSON

Not effective-dated. Select based on employee ID.

PERS_DATA_EFFDT (personal data effective date)

Max Effdt (maximum effective-dated) row is less than or equal to the segment end date. If referenced in a slice, looks at Max Effdt rows that are less than or equal to the slice end date.

JOB

The Max Effdt row is less than or equal to the segment end date. If referenced in a slice, looks at Max Effdt rows that are less than or equal to the slice end date.

PER_ORG_ASGN (person organization assignment)

Not effective-dated. Select based from the employee's organizational instance number

PER_ORG_INST (person organization instance)

Not effective-dated.

CONTRACT_DATA

Not effective-dated. Select based on CONTRACT_NUM (contract number) from the selected job record.

WKF_CNT_TYPE (workforce contract type)

The Max Effdt row is less than or equal to the segment end date where the contract number on this row matches the contract number on job. You can use CONTRACT_NUM from JOB or from CONTRACT_DATA, because the system synchronizes them. If the contract number is referenced in a slice, use the slice end date.

COMPENSATION

Includes all comp_effseq rows for each rate code (comp_ratecd) where Effdt and Effseq (effective sequence) match Effdt and Effseq from the Job table.

Note. These HR tables are discussed in detail in the HR documentation.

See Increasing the Workforce.

Database System Elements and Currency

Some database system elements are monetary values. The value stored in the field is stated in terms of the currency with which the value is associated. This currency may or may not be the same as the Global Payroll processing currency.

Note. Use caution when you use the COMPRATE system element (from the Job record). That system element is populated based on multiple components. It is not dynamically updated with a new currency exchange rate type and effective date when it is referenced during a payroll calculation. Instead, it's populated using the currency exchange rate and effective date from HR when it's updated.

When these system elements are resolved, if the currency code of the HR record doesn't match the processing currency of the pay run, the system converts from HR currency to the processing currency defined on the GP Pay Entity page.

This table lists the monetary fields on the Job record:

Field on Job Record

Associated Currency

Comprate

Currency Cd

Annual Rate

Currency Cd

Monthly Rate

Currency Cd

Daily Rate

Currency Cd

Hourly Rate

Currency Cd

Shift Rate

Currency Cd

Change Amount

Currency Cd

Annual Benefits Base Rate

Currency Cd

Similarly, system elements that are stated in a specified frequency will be resolved in the same way that currency-controlled system elements are resolved. The Comprate field on the job record is stated in the comp frequency stored in the job record. This frequency may differ from the calendar frequency being processed in Global Payroll. Any database system element that is frequency-controlled is resolved in the calendar frequency.

System-Computed Elements

System-computed elements appear on the output results table only if they are used, provided that the appropriate output options on the Source And Use page are selected.

During batch processing, all database system elements are retrieved and stored in arrays, whereas system-computed element values are retrieved and set by the appropriate processing application. For example, when you process absences, the system populates only those system elements that are specific to absences.

With system-element processing:

Click to jump to top of pageClick to jump to parent topicPages Used to Modify and View System Elements

Page Name

Definition Name

Navigation

Usage

System Element Name

GP_PIN

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, System Elements, System Element Name

Name the element and define its basic parameters.

Source And Use

GP_SYSTEM_PIN

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, System Elements, Source and Use

Displays whether a system element is a system-computed element or a database system element. For a database system element, it also displays the record and field that populates it and indicates whether the field is SetID-controlled.

System Elements by Source

GP_SYSTEM_PIN_INQ

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, View System Elements by Source, System Elements by Source

View system elements by source.

System Elements - Comments for Element <name>

GP_PIN_SEC

Click the Comments link on the System Element Name page.

View detailed comments about system-computed system elements that PeopleSoft delivers.

See Entering and Viewing Element Comments.

Click to jump to top of pageClick to jump to parent topicNaming System Elements

Access the System Elements - System Element Name page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, System Elements, System Element Name).

Note. You name every element and define its basic parameters on an element name page with the object name of GP_PIN. The page title and general appearance of this page change based on the type of Global Payroll element that you name and define. All of the fields on this page are documented in another chapter in this PeopleBook.

For each system-computed system element that is delivered by PeopleSoft, you can view detailed comments including a general description, when the system element is available, and where the element is used by clicking the Comments link. This is useful information when you want to learn more about how the system uses a specific system element.

See Also

Entering and Viewing Element Comments

Defining Element Names

Click to jump to top of pageClick to jump to parent topicViewing System Element Details

Access the Source And Use page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, System Elements, Source and Use).

Record

Displays the record from which the system element obtains its information.

Field Name

Displays the field from which the system element obtains its information.

SetID Controlled

Selected if the field is controlled by SetID. Elements that are controlled by SetID have field name and prompt view values.

Use As Chart Field

For database fields, you can select this check box to use the element as a ChartField. ChartFields are applicable when you integrate Global Payroll with PeopleSoft General Ledger.

Prompt View

Elements that are controlled by SetID or used as ChartFields have a prompt view specified. If a SetID controlled system element is used as a supporting element override for positive input, it also requires a prompt view.

SetID Element

Displays the SetID field name for the system element.

See Also

Selecting ChartFields for Allocating Costs to General Ledger

Business Units, Tablesets and SetIDs

Click to jump to parent topicDefining Array Elements

To define array elements, use the Arrays (GP_ARRAY) component.

This section provides an overview of arrays and batch processing of arrays, and discusses how to:

Click to jump to top of pageClick to jump to parent topicUnderstanding Array Elements

Arrays enable you to retrieve data from external sources such as HR tables—data that you need to use, evaluate, or process in your payroll rules.

To build an array, you assemble a Structured Query Language (SQL) statement out of FROM, SELECT, and WHERE clauses using the Array Definition component.

Note. After you construct your SQL statement, you can also define any formulas; you need to evaluate the data retrieved by the array.

Do this on the Array Processing Formulas page.

Note. Arrays are not effective-dated. Any changes are likely to affect retroactive processing.

Click to jump to top of pageClick to jump to parent topicUnderstanding Batch Processing of Arrays

Arrays can be used to access data in database tables or views that are not delivered by system elements. They do not resolve to a value but instead invoke processing.

You can create either payee-based arrays or non-payee-based arrays on the Field Map and Keys page. Payee-based arrays are resolved as of the slice or segment that is currently being resolved.

Arrays must be resolved for every segment and slice. If any element set by an array is used by another element that's being sliced, the array itself should be added to the event list to ensure that the array and all return column elements are also sliced. You must enter the array into the event list.

Payee-Based Array Processing

The system performs these steps when processing payee-based arrays:

  1. Arrays call the database the first time that they are encountered in a calendar run.

    All of the rows of data that fit the WHERE criteria (based on keys entered) are pulled into memory. The cursors are sorted by employee ID in ascending order, by employee record number in ascending order, and by effective date in descending order.

  2. For each payee, a cursor is set to access the appropriate rows of data (the Payee and Effective Date fields based on field use on the Field Map and Keys page).

    Payee-based arrays are aligned per payment based on the pay period end date. If segmentation occurs and the array is on the event list or is being used in an earning, deduction, or absence element that's being sliced or segmented, the array must be aligned by slice or segment end date.

  3. The array process formulas are applied against the data that is stored in memory (for the payee cursor set above), based on the process code.

  4. The database field is resolved to the last row of data against which the process formulas were applied.

Whenever the array is accessed, steps 2 through 4 are performed again. Step 1 is performed only if the payee has changed or if a new slice or segment is being resolved.

Non-Payee-Based Array Processing

When processing non-payee-based arrays, the system performs the following steps:

  1. Arrays call the database the first time they are encountered in a calendar run.

    All rows of data that fit the WHERE criteria (based on keys entered) are pulled into memory, so most effective-dated logic should be within the process formula logic.

  2. If the table is effective-dated, the lookup formula references the system element that refers to the correct date (segment, slice, period).

    If segmentation occurs and the array is on the event list or is being used in an earning, deduction, or absence element that's being sliced or segmented, the array must be aligned by slice or segment end date. Arrays can return multiple rows from the database. The process formulas are applied against the rows.

  3. The array process formula is run.

  4. The database field is resolved to the last row of data against which the process formula was applied.

Whenever the array is accessed, steps 2 through 4 are performed again. Step 1 is performed only if the Reload for Each Resolution or Reload for Each Segment value is selected on the Field Map and Keys page.

See Also

Arrays Used in Batch Processing (Technical)

Click to jump to top of pageClick to jump to parent topicPages Used to Define Array Elements

Page Name

Definition Name

Navigation

Usage

Array Name

GP_PIN

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Arrays, Array Name

Name the element and define its basic parameters.

Field Map and Keys

GP_ARRAY_KEYS

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Arrays, Field Map and Keys

  • Select the database table for the FROM clause of the SQL statement.

  • Define the keys and retrieval criteria for the array and the WHERE clause of the SQL statement the system uses when retrieving data for the array.

  • Define the fields to be returned and the elements to be filled by the array. This provides the data for the SELECT clause of the SQL statement and determines the elements to resolve from this array call. You also use this page to define the sort order for retrieving rows from a database.

Processing Formulas

GP_ARRAY_PROCESS

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Arrays, Processing Formulas

Define all required formula processing.

Click to jump to top of pageClick to jump to parent topicNaming an Array Element

Access the Array Name page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Arrays, Array Name).

Because arrays are temporary tables that store results only during processing, storing the results after processing isn't necessary. The system deselects the Store and Store if Zero check boxes and makes them unavailable for entry.

In addition, arrays are not effective-dated, so this page has no definition as of date. To change an array definition, create a new array and new effective-dated elements that reference it. If a database table or view is renamed, create a new array.

Note. You name every element and define its basic parameters on an element name page with the object name of GP_PIN. The page title and general appearance of this page change based on the type of Global Payroll element you are naming and defining. All of the fields on this page are documented in another chapter in this PeopleBook.

See Also

Defining Element Names

Click to jump to top of pageClick to jump to parent topicSelecting and Defining Information for the SQL Statement

Access the Field Map and Keys page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Arrays, Field Map and Keys).

Record (Table) Name

Select the table for the SQL statement to use from the list of PeopleSoft defined tables. In the FROM clause of the SQL statement, the system appends the prefix PS_ to the selected table name.

You can also select views. The prompt list displays all SQL tables and views in the database.

Loading Option

Select a value to control how often the array data are refreshed from the database.

Values are:

Employee-based look-up: Select to create a payee-based array.

Data is retrieved once for each payee. When that person is processed, the array storage becomes available for the next payee.

Load once (small table): Select to create a non payee-based array. Data is retrieved only once the very first time the array is referenced within the process. Compared to the two "Reload" alternatives, this option can significantly improve performance because the process only accesses the database once to load data. As indicated, this should be used only with smaller tables. The buffer for all arrays with this option combined can only hold 5000 rows. If the data in the table is changed by the process itself (and it is desirable to reflect these updates in the process, Load once is not a good option.

Reload for each resolution: Select to create a non payee-based array.

Data is retrieved from the database every time the array is resolved.

Reload for each segment: Select to create a non payee-based array.

Data is retrieved from the database once per segment being processed, regardless of the number of times the array may be resolved within each segment.

Note. The loading option that you select controls the key types that you can enter in the Key Type field.

See PeopleTools: Data Management PeopleBook

Map Retrieved Fields to Variable Elements

Specify the columns to be retrieved from selected rows in the Array - Fields Retrieved group box (this is the SELECT part of the SQL statement). Also specify the variable elements to populate with the selected columns' values. The system orders the Keyed by Employee arrays by employee ID (and employee record number and effective date, if specified), with employee ID and employee record number in ascending order and effective date in descending order.

Field Use

Select from these options:

Monetary: When monetary conversion is required.

Pointer: To specify that a column contains a PIN.

Other: (default) For all other cases.

Field

Select a field from the list of columns in the database table. The system displays all columns in the database table that can be used in the SELECT AND/OR ORDER BY clause.

Variable Element Name

Define the host variable to populate with the value of the selected field. The Variable Element Name field is not required. If this field is blank, only the database field name column value is used in the ORDER BY clause.

Note. You cannot use the same variable name for two or more different field names.

Currency Field

If the field being retrieved from the database stores a monetary amount, enter a currency field name, indicating the column name of the field in the database that stores the corresponding currency code. If the currency code doesn't equal the processing currency, the system converts the monetary amount in the database to the processing currency. This field is available for entry only if you select Monetary in Field Use.

Order By

Define the sort order—ascending, descending, or none—for retrieving rows from the database. This is crucial because, depending on the defined lookup formula, you may want only the first row retrieved or use special formula logic dependent on the order.

Note. The same field can be assigned to more than one Global Payroll variable, but it cannot be ordered in more than one way (for example, both ascending and descending).

Keys and Retrieval Criteria

Key Type

Select a key type.

If the Loading Option is Employee-based look-up, the key types are Effdt (effective date), EmplRcd (employee record number), EmplID (employee ID), and Other. Select Other if you want to use any other database field in the table that you are querying as a key.

If the Loading Option is Load once (small table), Reload for each resolution, or Reload for each segment, all key fields are defined as Other.

When specifying keys for a user-defined array, you generally define at least one key, but the system enables you to save this page without specifying keys. (In this case, the system loads the entire table.)

Warning! Changing the array keys clears the data in the Keys and Retrieved fields and the Processing Formulas pages.

Field

Enter the exact name of the record (table) column as defined in the database. This is the first half of the equation in the WHERE clause. For example, suppose that you have the equation WHERE EmplID equals System Element Payee ID1, EmplID is what you enter underField.

The field name must be the exact name of the column in the table in the database—not the field label or description.

Operator

Indicates the user in the WHERE clause. You can enter an operator only if the key type is Other. Valid operators are: <, <=, <>, =, >=, >, and N.A.

Element Type

Select Bracket, Formula, System Element, or Variable. You can enter an entry type only if the key type is Other.

Element Name

Select the element for the second half of the WHERE clause. For example, in the equation WHERE EmplID equals System Element Payee ID1, Payee ID1 is the element name. You can enter an element name only if the key type is Other.

Review Generated SQL Statement

Log statement at run time

Select this check box to view the text of the SQL statement dynamically generated by the array module during batch processing. You can direct the output display into a file by selecting the Redirect Output option in PeopleTools Configuration Manager.

View Resulting Query

Click to view the SQL statement in real time. The system displays what SQL is to be created to pull data into the array, and lists how many rows are in the table defined in the Record (Table) Name field.

Using System Elements as Key Values

Depending on your loading option, you can use EmplID, EmplRcd#, and Effdt as key fields.

If you select EmplID or EmplRcd as array keys, the system hides the Operator and Element Name fields and assumes an operator of equal to (=) current EmplID and EmplRcd#. For Effdt, the system assumes an operator of less than or equal to (<=) the date specified in the Compare Effdt (effective date) against field.

For example, if you select Employee-based look-up and enter a key type of EmplID (using field name EmplID), and a key type of EmplRcd# (using field name, EmplRcd#), the system builds a SQL statement that retrieves data for the current payee only.

Using Other as a Key Type in Payee-Based and Non-Payee-Based Arrays

If you are not using one or more of the three provided array key elements—or you want entries beyond those—specify a key field name, an operator, an entry type, and the correct element name.

  1. Select the correct operator for the key field (record column) in the WHERE clause.

  2. Select an entry type.

  3. Enter an element name corresponding to the entry type—this must be a defined element of the type that you selected.

This is the data that the system uses to build the WHERE clause of the SQL statement that it needs for retrieving data for the array. You can enter multiple key fields for your definition.

Note. If you enter multiple rows on the page, the multiple conditions are processed as AND conditions.

Example: User-Defined Key Structure

Say that you're searching the database for a row of data with a matching department ID.

You enter Other DEPTID = System Element DEPTID. The system looks for a row in the Department table (DEPT_TBL) with a DEPTID (department ID) that equals the value in the system element DEPTID for the payee currently being processed when it encounters this array.

Click to jump to top of pageClick to jump to parent topicDefining Formula Processing for an Array Element

Access the Arrays - Processing Formulas page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Arrays, Processing Formulas).

Processing Option

Select one of these values to determine when and how the system applies a formula. Values are:

By Formula, Apply all Rows: The system selects all the rows required for the array, applies the first formula to all rows, applies the second formula to all rows, and continues for all formulas.

By Row, Apply all Formulas: The system selects a row of data from the database and applies each formula on this page to that row. It then selects the next row and applies each formula to that row, continuing for all rows.

Look-up: The system selects a row of data from the database, applies each formula on this page to that row, selects the next row, and applies each formula to that row. The first formula that resolves to a value of 1 stops the loop. So if you are searching data for a particular value, the system stops looking when it finds that value.

Note. With regards to arrays with look-up processing, if you select a value of Look-up, but do not specify a formula value in the Formula Name field, the system uses the first row of data returned by the array.

Error Formula

Select an Error Formula Name for the system to use during error processing, if no rows are found.

Formula Name

Select the formula that the system applies to each row of data to resolve the array.

If you selected Look-up as the array processing option, select a Boolean formula here.

Note. Instead of using a formula, consider defining the array so that the desired row of data is always ordered first. Also, if the array will never return more than one row of data, and this row will always contain the desired data, no Formula Name field value is necessary with the processing option of Look-up.

Note. The system automatically assigns a sequence number to each formula. The sequence is unchangeable. If you make a mistake, delete all the items back to the mistake and add the formulas again in the correct order.

See Also

Defining Formula Elements

Click to jump to parent topicDefining Writable Array Elements

To define writable array elements, use the Writeable Arrays (GP_WRITE_ARRAY) component.

This section provides overviews of writable arrays, storage considerations for writable arrays, and batch processing of writable arrays, and discusses how to:

Click to jump to top of pageClick to jump to parent topicUnderstanding Writable Array Elements

Writable arrays are elements that you can use to populate user-defined result tables. You use PeopleSoft Application Designer to create the result table, then you use the writable array pages that are described in this section to define the element that populates the table during batch processing. Writable arrays are in many ways the opposite of standard arrays. Instead of reading values from a row in a table to user-defined variables, a writable array writes the values of user-defined elements into a row in a table.

Writable arrays make it easy for you to design reports that exactly meet your needs—each row in your table can produce a corresponding line of information in your report. You can also combine multiple tables to create a report, for example, use one table for a report header, one for the body of the report, and another for the footer.

Finally, writable arrays can also conserve valuable storage space by consolidating many vertical rows of information into a single horizontal row.

To define a writable array:

  1. Use PeopleSoft Application Designer to create the table that the writable array element populates.

    The first seven fields in the table must be the same as the keys in the basic result tables. You can also use some of the optional result table keys, such as INSTANCE or SLICE_BGN_DT, and include keys that are not used in the basic result tables, such as DEPTID.

    The seven fields are:

  2. On the Writable Array Name page, define the naming information for the writable array.

  3. On the Definition and Fields page, identify the table that the writable array is to populate, and map the elements that are to populate the table to the corresponding fields (columns) within the table.

Note. When you create a result table using a writable array, the table must include the basic segment status keys shared by all the standard result tables. You can include additional keys as well.

Click to jump to top of pageClick to jump to parent topicUnderstanding Storage Considerations for Writable Array Elements

While custom result tables can conserve storage space, they can also increase the need for space if they duplicate data from the standard result tables. Consider using writable arrays to consolidate or temporarily store the following types of results:

Because you may want to delete temporary data at different times, the management of the data in your result tables is up to you.

Click to jump to top of pageClick to jump to parent topicUnderstanding Batch Processing of Writable Array Elements

Typically, each call to a writable array element creates one row of data. To produce multiple rows of output, you can use loops within a subprocess section and arrays to call the writable array multiple times. Using pointers and variables, you can populate the same field in a writable array with values from different elements, as long as you do not map character and numeric elements to the same field.

Click to jump to top of pageClick to jump to parent topicPages Used to Define Writable Array Elements

Page Name

Definition Name

Navigation

Usage

Writable Array Name

GP_PIN

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Writable Arrays, Writable Array Name

Name the element and define its basic parameters.

Definition and Fields

GP_WRITABLE_ARRAY

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Writable Arrays, Definition and Fields

Identifies the table into which the writable array process inserts data. Also identifies the element that populates each column (field name) in the table.

Click to jump to top of pageClick to jump to parent topicNaming a Writable Array Element

Access the Writable Array Name page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Writable Arrays, Writable Array Name).

When a writable array resolves successfully, the element itself is set to one. Most likely, you will not want to store this value, so the Store and Store if Zero options on the Element Name page are not selected, by default. You can select them if you choose.

In addition, writable arrays are not effective-dated, so there is no definition as of date on the Writable Array Name page. If you need to change the element's definition, create a new writable array instead, and then create new effective-dated elements that reference the new writable array. If you rename a database table or view, create a new writable array.

Note. You name every element and define its basic parameters on an element name page with the object name of GP_PIN. The page title and general appearance of this page change based on the type of Global Payroll element that you are naming and defining. All of the fields on this page are documented in another chapter in this PeopleBook.

See Also

Defining Element Names

Click to jump to top of pageClick to jump to parent topicDefining Writable Array Records and Fields

Access the Definition and Fields page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Writable Arrays, Definition and Fields).

Note. The writable array must have a record name and at least one field name in order to save.

Record (Table) Name

Enter the name of the table that the writable array is to populate. The only tables available for selection are those containing the seven required key fields of a writable array.

The system appends the prefix PS_ to the table name and uses the new name in the INSERT clause of a SQL statement.

Insert Rows Immediately

Select if you are defining a writable array to generate data for immediate use by a standard array in the same process. This ensures that the data is present in the database when the standard array element is processed.

If this check box is not selected, the system does not immediately write data to the database table that the array is populating. It inserts the data at a later time using a bulk insert process.

Note. Not all relational database management systems provide bulk insert. For these, the rows will always be inserted one-by-one as they are processed.

Field Name

Enter the name of the writable array field that you want to populate. The list of available options includes only those fields that are included in the table that you selected in the Record (Table) Name field.

The order in which you add field name is not important.

Entry Type

Select the type of element that will populate the field.

Element Name

Select the element whose value the system uses to populate the writable array key field that you are defining.

Note. During processing, the system populates the array with the current value of the selected element. (Linking an element to a writable array field does not, in itself, cause the element to resolve.)

Click to jump to parent topicDefining Bracket Elements

To define bracket elements, use the Brackets (GP_BRACKET) component.

This section provides overviews of brackets, interpolation methods, and batch processing of brackets, and discusses how to:

See Also

Defining Element Names

Click to jump to top of pageClick to jump to parent topicUnderstanding Bracket Elements

Brackets enable you to create simple lookup tables. Based on a table that you define in a bracket, a bracket is used to look up data and assign certain values based on the lookup data. Brackets are also called bands and lookup tables.

Brackets can use one or more lookup values (search columns). Using a lookup value, bracket processing returns one or more columns that are available for use in other elements such as formulas.

Before defining a bracket, create any elements that you need to use in the bracket definition. For example, before building a bracket that lets you look up bonus amounts based on years of service, create the duration element that returns the years of service.

To define a bracket:

  1. Define the naming information for a bracket on the Bracket Name page.

  2. Define the lookup rules for the bracket on the Lookup Rules page.

  3. Select the search key values and the return column values that you'll use in the lookup table on the Search Keys/Return Columns page.

  4. Enter the lookup values on the Brackets - Data page.

Click to jump to top of pageClick to jump to parent topicUnderstanding Interpolation Methods

When a search key doesn't exactly match the lookup values defined for the bracket (on the Bracket Data page), the interpolation method defines how the system calculates the values that the bracket returns.

You can select one of the following three interpolation methods on the Lookup Rules page:

For example, suppose that you create a bracket to calculate a bonus value based on years of service, this table lists the search keys and return columns:

Search Keys (Years of Service)

Return Column (Bonus Amount)

5

30%

10

60%

If the years of service is seven years, the value returned depends on the interpolation method that you selected. This table lists the values returned for each method:

Interpolation Method

Return Value

Description

Linear

42%

The system uses a formula to calculate the value.

Use Nearest

30%

The system selects five years and the value from its row, because five years is closer to seven years than ten years.

Use Next Higher

60%

The system selects the next-higher key, ten years, and returns the value from its row.

Use Next Lower

30%

The system selects five years, and returns the value from its row.

Use Lowest and Highest Option

For the linear interpolation method, the system looks for the next-lower and next-higher rows to calculate the return value. When there isn't a lower or higher row, you can use the Use Lowest/Highest Option check box on the Lookup Rules page to indicate whether the system should take the lowest or highest matching option.

For example, suppose that the bracket is defined with these search keys and return columns:

Search Keys (Dept ID, Years of Service)

Return Columns (Bonus Percentage)

ABC, 1

10

ABC, 3

12

ABC, 5

15

DEF, 1

11

DEF, 3

13

DEF, 5

15

If the department ID is ABC and the employee has six years of service, the next-lower row is for department ID, ABC, and five years of service. However, there is no next-higher row. If the Use Lowest/Highest Option check box is selected, the system uses the highest option of Dept ABC and Years of Service = 5.

Rounding Rules

With the linear interpolation method, you can use a rounding rule to specify the type of rounding for the returned value.

For example, you're dealing with bonus amounts or rates based on the number of hours worked during a quarter (QTD hours), and you need to use linear interpolation to determine the value of the bonus amount or rate if a payee's hours don't match the values defined on the Bracket Data page. You may want to round the return column result up to 0 decimal places.

Suppose that the bracket data includes the information that appears in the following table:

Search Keys - Accumulator QTD Hours

Return Column - Bracket - Bonus Amount

200

2000

300

2500

500

3000

Assume a payee who has worked 303 QTD hours. Using linear interpolation, the system normally returns:

(303.5 − 300) / (500 − 300) = 3.5/200 = 0.017500

The result is:

2500 + (0.017500 * (3000-2500) = 2500 + (0.017500 * 500) = 2500+ 8.75 = 2508.75

If you apply a rounding rule element, you round up to 0 decimal places and the bracket return column equals 2509 instead of 2508.75.

Click to jump to top of pageClick to jump to parent topicUnderstanding Batch Processing of Bracket Elements

In bracket processing, the system looks up a row based on the key values and returns a bracket value.

The Bracket elements themselves always resolve to the value of the first column returned. They are resolved as they're encountered in the process. If an element in the return column of a bracket is encountered during processing, it doesn't automatically invoke resolution of the bracket, because the process doesn't know whether the element is associated with this bracket.

Brackets and all return columns are populated as of applicable slice and segment end dates that are used when encountered during processing, with these criteria:

How Brackets Use Interpolation Methods

Three factors need to be considered:

This table clarifies how batch processing treats each interpolation method:

Interpolation Method

Batch Process

Use Nearest

If mismatch key is nonnumeric, go to Error Processing Options.

If mismatch key is numeric determine whether next-lower and next-higher values exist:

  • If only next-lower value exists, use that row.

  • If only next-higher value exists, use that row.

  • If both next-lower and next-higher values exist, determine which value is nearer and return that row (if exactly halfway between, return the higher row).

Use Next Lower

Determine whether next-lower row exists:

  • If next-lower row exists, use that row.

  • If next-lower row doesn't exist, look at the Use Lowest/Highest Option check box (if lower value doesn't exist).

  • If Use Lowest/Highest Option check box is selected, use the lowest row where keys match.

  • If Use Lowest/Highest Option check box is not selected, go to Error Processing Options.

Use Next Higher

Determine whether next-higher row exists:

  • If next-higher row exists, use that row.

  • If next-higher row doesn't exist, look at the Use Lowest/Highest Option check box (if higher value doesn't exist).

  • If Use Lowest/Highest Option check box is selected, use the lowest row where keys match.

  • If Use Lowest/Highest Option check box is not selected, go to Error Processing Options.

Linear

If mismatch key is nonnumeric, go to Error Processing Options.

If mismatch key is numeric determine whether next-lower and next-higher values exist:

  • If only next-lower value or next-higher row exists, look at Use Lowest/Highest Option check box.

  • If Use Lowest/Highest Option check box is selected, use that row (no linear interpolation required).

  • If Use Lowest/Highest Option check box is not selected, go to Error Processing Options.

    If both next-lower and next-higher values exist:

  • In relation to the keys:

    • Determine the difference between the next-lower and next-higher rows (Key Difference 1).

    • Determine the difference between your value and the next-lower value (Key Difference 2).

    • Determine ratio by dividing Key Difference 2 by Key Difference 1 (Key Ratio).

  • For each return column:

    • Determine the difference between the values for the next-lower and next-higher rows (Return Column Difference 1).

    • Apply Key Ratio to the Return Column Difference (Return Column Difference 2).

    • Add Return Column Difference 2 to the value from the next-lower row. This is the value that should be returned for the return column.

Additional Notes About Batch Processing for Bracket Elements

Search keys are considered in the order in which they are entered on the bracket definition. Values are in ascending order (based on key order).

For all interpolation methods, if all keys match, use that row. For all interpolation methods, try to match on keys sequentially (first key, second key, and so on).

What to Do When Keys Are Mismatched

If there's a mismatch on the first key:

Click to jump to top of pageClick to jump to parent topicPages Used to Define Bracket Elements

Page Name

Definition Name

Navigation

Usage

Bracket Name

GP_PIN

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Brackets, Bracket Name

Name the element and define its basic parameters.

Lookup Rules

GP_BRACKET1

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Brackets, Lookup Rules

Define the lookup rules for a bracket.

Search Keys/Return Columns

GP_BRACKET2

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Brackets, Search Keys/Return Columns

Identify the search keys and the return columns for the bracket.

Brackets - Data

GP_BRACKET3

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Brackets, Data

Enter lookup values. The search key values and the return column values that you selected in the Brackets - Search Keys / Return Columns page appear here.

Click to jump to top of pageClick to jump to parent topicNaming Bracket Elements

Access the Bracket Name page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Brackets, Bracket Name).

Note. You name every element and define its basic parameters on an element name page with the object name of GP_PIN. The page title and general appearance of this page change based on the type of Global Payroll element that you are naming and defining. All of the fields on this page are documented in another chapter in this PeopleBook.

See Also

Defining Element Names

Click to jump to top of pageClick to jump to parent topicDefining Lookup Rules for a Bracket Element

Access the Lookup Rules page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Brackets, Lookup Rules).

Error Processing Options

Select from the following values:

Generate Error: Stops processing and generates an error.

Continue Process: Continues processing without returning any value.

Outside Table Limits

Defines what happens if the key values are over or under those that are defined in the table:

Use First Row if Under: Select if key values are under those that are defined in the table.

Use Last Row if Over: Select if key values are over those that are defined in the table.

Interpolation Method

Select an interpolation method that defines the values to return if the system doesn't find an exact match; for example, if the key values are between two rows on the table. All interpolation methods use only one search key, the first mismatched one. Select from the following values:

Linear: Uses a mathematical formula to create a prorated value based on the next-higher and next-lower keys (works only with brackets that have one or two numeric keys and with numeric result columns).

Use Nearest: Uses the value from the row that has the nearest key (works only with brackets that have numeric or date keys).

Use Next Higher: Uses the value from the row that has the next-higher key (works with any bracket).

Use Next Lower: Uses the value from the row that has the next-lower key (works with any bracket).

See Understanding Interpolation Methods.

Use Lowest/Highest Option

When using linear interpolation, the system matches on all search columns that have already been matched. Then it looks for the next-lower and next-higher rows where the search columns match. When there isn't a lower or higher row where search columns match, you can use the Use Lowest/Highest Option check box to indicate whether the system should take the lowest or highest matching option.

See Understanding Interpolation Methods.

Rounding Rule Element

With linear interpolation, you can use a rounding rule to specify the type of rounding for the returned value. The system applies this rounding rule to all return columns whose field format is numeric (decimal or monetary), because linear interpolation takes the ratio of the next-lower return column value and the next-higher value and returns the prorated value based on the ratio that is above the next-lower value. The result might be an excess of decimal places.

See Understanding Interpolation Methods.

Click to jump to top of pageClick to jump to parent topicIdentifying Bracket Search Keys and Return Columns

Access the Search Keys/Return Columns page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Brackets, Search Keys/Return Columns).

Search Columns

In the Search Columns group box, select the keys that the system uses to search the bracket data. For each key, select the Search Key Type (element type) that you're entering. Then select the corresponding Element Name. You can enter up to five search keys.

Return Columns

In the Return Columns group box, select the columns that tell the system where to store the values returned by the lookup. For each column, select the Return Entry Type (element type) that you're entering. Then select the corresponding Element Name. The bracket itself is the first returned column. You can enter up to eight return columns.

Click to jump to top of pageClick to jump to parent topicEntering Bracket Lookup Values

Access the Brackets - Data page(Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Brackets, Brackets - Data).

Bracket Search Keys and Return Column Values - Search Keys

Enter the values of the search keys.

Bracket Search Keys and Return Column Values - Return Columns

Enter the values to be returned for each search key value, based on your entries on the Search Keys/Return Columns page. You can enter multiple return values.

Click to jump to parent topicDefining Rate Code Elements

To define rate code elements, use the Rate Codes (GP_RATE_CODE) component.

This section provides overviews of rate code mapping, the use of rate codes in earnings, and batch processing of rate codes, and discusses how to:

Click to jump to top of pageClick to jump to parent topicUnderstanding Rate Code Mapping

You can use rate code elements to retrieve multiple components of pay that have been defined in HR—including base pay and non base-pay components.

To have the system retrieve the rate codes set up in HR, matching rate code elements must be defined in Global Payroll and mapped to the corresponding HR rate codes. A HR rate code can be associated with only one Global Payroll rate code element.

Note. Global Payroll cannot map to rate matrices. Global Payroll can only map to simple rate codes.

Rate code elements can be defined and mapped to HR rate codes in two ways:

  1. If you install Global Payroll after creating rate codes in HR, use the Rate Codes - Definition page to create rate code elements and map them to the corresponding rate codes in HR.

    Mapping an element to a HR rate code makes the element take on the values of the HR rate code.

  2. If Global Payroll is installed when you create rate codes in HR, the creation of the rate code element is dependant on if a row exists on the User Rules Profile page for the rate code creators user ID.

    1. If there is an entry on the User Rules Profile page for the User ID of the person who is creating the Rate Code in HR a matching rate code element is created automatically in Absence Management. This rate code will have the same Used By and Country values on the Rate Code Name page that are defined for the User ID of the person creating the rate code. If a different one is desired, a user will a user ID of All Countries will have to modify the rate code with the applicable change to the Used By and Country fields.

    2. If there is no entry on the User Rules Profile page for the User ID of the person creating the Rate Code in HR, the system does not create a rate code in Global Payroll. It handles it just as in the same manner as described in #1 above. A user with the appropriate User ID set up on the User Rules Profile page will have to go into the Rate Code element in Global Payroll to create the rate code element.

See Restricting User Access.

You can display the rate code elements through the Rate Codes - Definition page in Global Payroll. You can also use the page to map the element to a different rate code.

This table lists the values that appear on the Rate Codes - Definition page:

Field

Value

Name

Same as HR Rate Code Name

Element Type

Rate Code (RC)

Description

HR Rate Code description

Field Format

Decimal

Use Defn As Of

Calendar Period End Date

Always Recalculate

Off (No)

Owner

Customer Maintained

Class

Not Classified

Used By

Same as the Used By value defined on the User Rules Profile page for the person creating the Rate Code in HR.

Country

Same as the Country value defined on the User Rules Profile page for the person creating the Rate Code in HR.

Industry/Region

Blank

Category

Blank

Override Levels

All options set to Off (No)

Store

On (Yes)

Store if Zero

On (Yes)

Customer Fields

Blank

Comments

Blank

Click to jump to top of pageClick to jump to parent topicUnderstanding the Use of Rate Code Elements in Earning Definitions

Rate code elements return the values of rate codes defined in HR. To use a rate code to calculate a payee's earnings, use the rate code in the earning element definition—either directly, as part of the earning calculation rule, or within a formula or other element used by the earning calculation rule.

Example

A certain payee's monthly pay has three components—a base amount, merit amount, and ten percent bonus that is based on the monthly total of base pay plus merit pay—and the following rate codes are defined in HR:

BASE = 1000 (monthly earning)

MERIT = 100 (monthly merit)

BONUS = 10 percent (monthly bonus)

For Global Payroll to retrieve this rate information from HR and use it in calculations, corresponding rate code elements must be defined in Global Payroll and mapped to the HR rate codes. This table shows the mapping:

HR Rate Code

Corresponding Global Payroll Rate Code Element

BASE

BASE

MERIT

MERIT

BONUS

BONUS

In Global Payroll, you've also defined an accumulator (SALARY TOTAL) to keep track of the total of base pay plus merit pay for each calculation (to facilitate monthly bonus calculations), and you want to use the rate code data defined in HR to calculate a payee's monthly pay. In this case, you need to create three earning elements in Global Payroll:

Note. To have Global Payroll retrieve rate code information from HR, include the rate code element in the definition of the earning or deduction element.

You typically use rate code elements when defining an earning element on the Earnings Calculation page. This table shows how you might use a rate code element as a component of an earning calculation rule:

Rate Code Type

Earning Calculation Rule

Component Information

Flat Amount

Amount

Amount = rate code element

Percent

Base * Percent

Base = anything (usually an accumulator)

Percent = rate code element

Points

Unit * Rate

Rate = anything (typically a formula that calls an array to retrieve the appropriate point value from the Company table and applies FTE, if applicable)

Units = rate code element

Hourly

Unit * Rate

Rate = rate code element

Units = anything (typically positive input)

Hourly + Flat Amount

Unit * Rate

Rate = formula; can take flat amount rate code element and add to a calculated hourly amount

Units = anything (typically positive input)

Note. PeopleSoft recommends that when using a non base-pay rate code as a component of an earning element, you assign the earning element by payee on the Element Group Members page. Then, during processing, the system runs through the non base-pay hierarchy for only those payees who have non base-pay earning for the pay period.

Warning! The order of resolving rate code elements—including rate code elements in earning elements—is extremely important.

See Also

Ordering Elements and Sections in a Process List

Click to jump to top of pageClick to jump to parent topicUnderstanding Batch Processing of Rate Code Elements

When the system encounters a rate code element during the payroll process, it calls the Rate Code PIN Resolution program, which first determines whether the element, effective on the calendar period end date, represents a base pay rate code or a non base-pay rate code. It then follows the hierarchy for base pay or non base-pay rate code elements, as appropriate, to resolve the rate code.

Criteria for Selecting the Job Row

For both base pay and non base-pay rate code elements, Global Payroll uses the RATE AS OF DATE system element to determine to which maximum effective-dated job row it refers for the rate code. The EmplID, EmplRcd#, and payment keys on the selected job row must match the current payment's corresponding values, or the payment is placed in error.

The FTE factor that applies to some rate codes is retrieved from the maximum effective-dated job row that is less than or equal to the RATE AS OF DATE or slice end date where the payment keys match.

Currency Conversion

When the currency code for a flat amount, hourly, or hourly plus flat amount rate code, as defined in HR, doesn't match the processing currency, Global Payroll performs its standard currency conversion during processing. That is, it uses the payee's effective-dated exchange rate type to perform the conversion.

Note. Currency conversion is not required on percent or point rate codes, because returned values are non monetary.

Frequency Conversion

Global Payroll also performs frequency conversion on any flat amount or hourly plus flat amount rate code, where the corresponding frequency code in HR doesn't match the calendar period frequency. The system annualizes the rate code using the corresponding frequency factor from HR. It then deannualizes for the calendar period frequency (using the applicable frequency factor). Define all earning elements that use rate codes as Use Calendar Period Frequency.

Note. Frequency conversion is not required on percent or point rate codes, because returned values are non monetary.

Resolving Multiple Instances of the Same Rate Code Element

If the PS_COMPENSATION record contains multiple instances for the same rate code (base pay or non base-pay), the system evaluates each instance separately, sums the instances, and returns one value to the rate code element. Global Payroll references two system elements, RATE CODE GROUP and FTE INDICATOR, and applies the following rules:

For example, if a flat amount rate code has one instance in which FTE applies, Global Payroll uses the FTE_COMPRATE for this instance. If a second instance indicates that FTE doesn't apply, the system uses the COMPRATE field value for the second instance and sums the two instances.

Hierarchy for Resolving Base Pay Rate Code Elements

When the system encounters a rate code element that's mapped to a HR base pay rate code, it finds the appropriate rows on the PS_COMPENSATION record, where the element matches the rate code. It then identifies the value to be returned, based on the rate code type, as shown in this table:

Rate Code Type

Fields Evaluated on PS_COMPENSATION

Value Returned for Rate Code

Percent

COMP_PCT

Percent

Points

COMP_RATE_POINTS

Points

Flat Amount

COMPRATE and

FTE_INDICATOR

If FTE_INDICATOR = Yes, return COMPRATE * FTE factor (stored on JOB) If FTE_INDICATOR = No, return COMPRATE

Hourly

COMPRATE

Hourly rate

Hierarchy for Resolving Non Base-Pay Rate Code Elements

When the system encounters a rate code element that's mapped to a HR non base-pay rate code, it derives the rate from the following hierarchy, stopping when it finds the rate:

The system identifies the value to be returned, based on the rate code type and FTE_INDICATOR, as shown in this table:

Rate Code Type

Fields Evaluated on PS_COMPENSATION

Value Returned for Rate Code

Percent

COMP_PCT

Percent

Points

COMP_RATE_POINTS

Points

Flat Amount, or Hourly + Flat Amount

COMP_RATE

FTE_INDICATOR

If FTE_INDICATOR = Yes, return COMPRATE * FTE factor (stored on JOB) If FTE_INDICATOR = No, return COMPRATE

Hourly

COMPRATE

Hourly rate

Click to jump to top of pageClick to jump to parent topicCommon Elements Used in This Section

Base pay components

Components that contribute to a payee's base pay are called base pay components. All base pay components are stored in the PS_COMPENSATION record in HR, but they can be overridden through the Payee Element Assignment page or Positive Input page in Global Payroll. (Hourly plus flat amount is not valid for base pay components.)

Multiple components of pay

This functionality enables your organization to compensate a payee at more than one rate of pay, such as regular pay and merit pay. Components can represent a flat amount, hourly rate, hourly rate plus flat amount, percentage of the worker's compensation package, or salary points.

Non-base-pay components

Components that do not contribute to base pay are called non base-pay components and may or may not be stored in the PS_COMPENSATION record. When you run the payroll process, the system follows a hierarchy to determine the applicable rate.

Click to jump to top of pageClick to jump to parent topicPages Used to Create Rate Code Elements

Page Name

Definition Name

Navigation

Usage

Rate Code Name

GP_PIN

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Rate Codes, Rate Code Name

Name the element and define its basic parameters.

Rate Codes - Definition

GP_RATE_CODE

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Rate Codes, Definition

Create a rate code element and map it to a rate code defined in HR. You can also use the page to view rate code elements and change the mapping.

Click to jump to top of pageClick to jump to parent topicNaming Rate Code Elements

Access the Rate Codes - Rate Code Name page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Rate Codes, Rate Code Name).

Note. You name every element and define its basic parameters on an element name page with the object name of GP_PIN. The page title and general appearance of this page change based on the type of Global Payroll element that you are naming and defining. All of the fields on this page are documented in another chapter in this PeopleBook.

See Also

Defining Element Names

Click to jump to top of pageClick to jump to parent topicCreating a Rate Code Element

Access the Rate Codes - Definition page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Rate Codes, Definition).

Compensation Rate Code

Enter the HR rate code to which you want to map this element. When you select the rate code, the lower half of the page displays information that is defined for the rate code in HR. You cannot change this information in Global Payroll.

Frequency Conversion

This check box is selected by default to indicate that the system is to perform frequency conversion (annualization and deannualization) on the value returned by the rate code.

Deselect this check box if you want the system to return the value from the rate code definition without performing frequency conversion.

Generate Warning

This check box applies only to rate codes that represent a base pay component. It is selected automatically to indicate that the system generates a warning message during batch processing if it does not find the rate code on the payee's compensation record.

Deselect the check box if you do not want the system to generate a warning message in these situations.

See Also

Understanding Data Retrieval from HR

Click to jump to parent topicDefining Fictitious Calculation Elements

To define fictitious calculation elements, use the Fictitious Calculations (GP_FICT_CALC) component.

This section provides an overview of fictitious calculation elements and batch processing of fictitious calculation elements, and discusses how to:

Click to jump to top of pageClick to jump to parent topicUnderstanding Fictitious Calculation Elements

You can use fictitious calculation rules to perform temporary calculations, which enable the system to calculate something and return a value without having to store it.

A fictitious calculation is a sub calculation that is run during a normal calculation to determine a net that would be computed if certain parameters were used. This result is used for further processing in the normal calculation. A fictitious calculation always starts from inside a normal calculation and is run for one payee and for a specified set of periods.

The intermediate results of a fictitious calculation are not needed and are ignored, except for the small subset of results brought forward to the normal calculation.

Note. A fictitious calculation is not a retroactive process because there are no changes to the results of the previous period. No new versions, deltas, or adjustments are created. No results are stored. Also, certain values from the current period are passed to the previous period calculation to override values used in the original calculation.

Click to jump to top of pageClick to jump to parent topicUnderstanding Batch Processing of Fictitious Calculation Elements

During the calculation phase of batch processing, the system uses a payment loop to calculate payments. When the payment loop process detects that a fictitious calculation is needed, it passes control to a fictitious calculation application, which performs the following steps:

  1. Reads the fictitious calculation definitions.

  2. Formats the input and output mapping arrays.

  3. Calls the PIN manager to resolve the previous period rule.

  4. Sets the fictitious calculation switch in SERVC copybook.

  5. Calls the GPPSERVC program, passing SERVC.

  6. Performs the required averaging and summing operations.

  7. Returns values to the PIN manager.

At this point, control is passed back to the service application. This application recognizes when a fictitious calculation is taking place, thereby running some processes and bypassing others, such as retroactive, payee selection, and the writing of output tables.

Intermediate results are not stored, except for debugging purposes, when a distinct set of fictitious results is written to the audit table.

The system processes calendars and segments in the order in which they were initially run.

Click to jump to top of pageClick to jump to parent topicPages Used to Define Fictitious Calculation Elements

Page Name

Definition Name

Navigation

Usage

Fictitious Calculation Name

GP_PIN

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Fictitious Calculations, Fictitious Calculation Name

Name the element and define its basic parameters.

Fictitious Calculations - Processing

GP_FICT_CALC1

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Fictitious Calculations, Processing

Define the previous period rule for a fictitious calculation that is used to determine the periods for which the fictitious calculation is performed. You can request that the original process be used or select a different process.

Input Mapping

GP_FICT_CALC2

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Fictitious Calculations, Input Mapping

Specify elements from the current period for overriding the original values for the selected elements in each of the fictitious periods.

Segment Mapping

GP_FICT_CALC3

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Fictitious Calculations, Segment Mapping

Select the accumulators that are to be forwarded to the next segment.

Output Mapping

GP_FICT_CALC4

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Fictitious Calculations, Output Mapping

Specify elements from the fictitious calculation (summed or averaged) to be passed back to the current period and stored in the current period's elements.

Click to jump to top of pageClick to jump to parent topicNaming Fictitious Calculation Elements

Access the Fictitious Calculation Name page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Fictitious Calculations, Fictitious Calculation Name).

Note. You name every element and define its basic parameters on an element name page with the object name of GP_PIN. The page title and general appearance of this page change based on the type of Global Payroll element you are naming and defining. All of the fields on this page are documented in another chapter in this PeopleBook.

See Also

Defining Element Names

Click to jump to top of pageClick to jump to parent topicDefining a Previous Period Rule for a Fictitious Calculation Element

Access the Fictitious Calculations - Processing page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Fictitious Calculations, Processing).

Historical Period Element

Select the element that determines which periods you want to recalculate during the fictitious calculation. The available elements are historical rules specifically created for fictitious calculation.

Use Original Process

Select to make the fictitious calculation use the original process. The process won't run the fictitious calculation a second time.

Use Specific Process

Select to make the fictitious calculation use a process other than the original process. Select the process that the system should use during this fictitious calculation in the Process Name field.

Note. During the fictitious calculation, system element values at the payee level and system-computed elements take on previous period values.

Click to jump to top of pageClick to jump to parent topicSpecifying Elements for Overriding Original Values

Access the Input Mapping page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Fictitious Calculations, Input Mapping).

Current Period Element

Enter an element whose value is to be passed to the previous period.

Fictitious Period Element

Enter a previous period element whose value is to be overridden in the previous period.

Click to jump to top of pageClick to jump to parent topicSelecting Accumulators to Forward to the Next Segment

Access the Segment Mapping page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Fictitious Calculations, Segment Mapping).

Fictitious Period Element

Enter an element whose value is to be forwarded to the next segment.

Click to jump to top of pageClick to jump to parent topicSpecifying Elements for Storage in the Current Period's Elements

Access the Output Mapping page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Fictitious Calculations, Output Mapping).

Fictitious Period Element

Enter an element whose sum or average (based on the calculation type of the previous period rule) value is to be passed to the current period.

Current Period Element

Enter an element to store the result of a calculation in a previous period.

Fictitious Period

Enter a number to designate the order in which the system shall process the fictitious periods. The lowest number is processed first, and so on.

Fictitious Period Element

Enter an element whose value is to be passed to the current period.

Current Period Element

Enter an element to store the result of the calculation in the previous period.

Click to jump to top of pageClick to jump to parent topicMoving Data by Using Fictitious Calculations

This table lists moving data from the current period to the fictitious one and vice versa.

FROM Element

Multiple Instances

Value Status

TO Element

Original Multiple Instances

Override Status

Primary Element

No

Period

Primary Element

Yes, sliced positive input

One instance for Period

Primary Element

Yes

Summed

Primary Element

Yes, sliced positive input

One instance for Period

Primary Element

No

Period

Supporting Element

Yes

One instance for Period

Primary Element

Yes

Summed

Supporting Element

Yes

One instance for Period

Primary Element

No

Period

Accumulator

Yes, sliced

One instance for Period

Primary Element

Yes

Summed

Accumulator

Yes, sliced

One instance for Period

Support-

ing Element

Yes

Period or Summed

Supporting Element

Yes

One instance for Period

Support-

ing Element

Yes

Period or Summed

Primary Element

Yes, sliced positive input

One instance for Period

Support-

ing Element

Yes

Period or Summed

Accumulator

Yes, sliced

One instance for Period

Accum-

ulator

Yes, sliced

Summed

Accumulator

Yes, sliced

One instance for Period

Accum-

ulator

Yes, user keys

Period or Summed

For the Current User Key Value

Accumulator

Yes, user keys

Only the one for the current user key value is over- ridden. The current user key is added to PINV.

Accum-

ulator

Yes, sliced

Summed

Supporting Element

Yes, sliced

One instance for Period

Accum-

ulator

Yes, sliced

Summed

Primary Element

Yes, sliced

One instance for Period

Accum-

ulator

Yes, user keys

Period or Summed

For the Current User Key Value

Supporting Element

Yes

One instance for Period

Accum-

ulator

Yes, user keys

Period or Summed

For the Current User Key Value

Primary Element

Yes, sliced positive input

One instance for Period

Click to jump to parent topicDefining Historical Rule Elements

To define historical rule elements, use the Historical Rules (GP_HIST_RULE) component.

This section provides overviews of historical rules and batch processing of historical rules, and discusses how to:

Click to jump to top of pageClick to jump to parent topicUnderstanding Historical Rule Elements

You can use historical rule elements to set up rules that retrieve data from prior periods. Historical rules can be used in formulas and fictitious calculations.

A historical rule can be associated with an earning or deduction element on the Formula Definition page. It can also be associated with any element that's stored in the Earnings/Deductions results table, Accumulators results table, or Other Elements results table. A historical rule can be used by fictitious calculation elements to find periods to recalculate.

Historical rule elements, retroactive calculations, and fictitious calculation elements differ in the following ways:

To define a historical rule:

  1. Define the naming information for the historical rule on the Historical Rules Name page.

  2. Define the rule type and the periods to be processed on the Processing Period page.

  3. Define the formula for a historical rule on the Parameters and Mapping page.

Click to jump to top of pageClick to jump to parent topicUnderstanding Batch Processing of Historical Rule Elements

You can attach a historical rule to an earning or deduction element on the Formula Definition page or to any element that's stored in the Global Payroll Earnings/Deductions results table (GP_RSLT_ERN_DED), Global Payroll Accumulators results table (GP_RSLT_ACUM), or Global Payroll Other Elements results table ( GP_RSLT_PIN). In addition, a historical rule can be used by fictitious calculation elements to find periods to recalculate.

Warning! The historical rule element reads the maximum version and the maximum revision in the payroll results. So, when an element is recalculated retroactively using forwarding retro, the delta is both included in the recalculated element and then forwarded to the current period. It is then included twice in the results read by the historical rule.

To bypass this issue you can select to Use Corrective Retroactive Behavior for segment accumulators on the Accumulator – Level page.

A historical rule resolves to one if it's successful and to zero if it's not successful. This works the same way as an array element. A historical rule can then be used in a formula such as:

IF HIST_RULE_TEST =1, THEN

Use variable elements populated by historical rule

ELSE

Generate an error

END-IF

A historical rule is set to one when either the end-of-process formula resolves without errors, or if that formula is not used in the processes, the stop-process-if-true variable is set to TRUE.

In all other situations, a historical rule is set to zero and SQL returns no data.

How the System Processes Historical Rule Elements

Here's how the system processes historical rules:

  1. The system dynamically creates SQL to load elements requested from the Global Payroll result tables.

    It can get data from multiple result tables at one time by using a SQL UNION, meaning direct access to the database each time the historical rule is called. A SELECT and a series of FETCHES are performed each time. The use of this element type affects performance.

  2. The system maps columns to variables.

    The variables are available for use in a formula.

  3. The first fetch establishes the keys for the first retrieved segment.

    The program continues fetching records until there is a break in the segment keys. It then populates the input and output interface copybook (PINL) with the values for the retrieved elements or with the null values for the elements in the element mapping that were not found. Then the program requests the resolution of Formula to Execute By Segment.

  4. The system performs formula resolution per segment.

  5. The system resolves an end of process formula for additional calculations such as averaging.

This table lists how calendars and segments are processed in the reverse order in which they were initially run:

Original Processing Sequence

Processing Sequence for Historical Rules

January absence calendar

January payroll calendar (segment 1, segment 2)

February absence calendar

February payroll calendar

February payroll calendar

February absence calendar

January payroll calendar (segment 2, segment 1)

January absence calendar

Formulas Used to Calculate the Preceding Values

Formulas to run by period (CUM_COMP):

Formula to calculate at the end (AVG_COMP):

CUM_PERIOD_SAL/CUM_NUM_PERIODS = AVG_COMP, where you calculate the earning value divided by the period of time.

See Also

Defining Proration Rules

Click to jump to top of pageClick to jump to parent topicPages Used to Define Historical Rule Elements

Page Name

Definition Name

Navigation

Usage

Historical Calculation Name

GP_PIN

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Historical Rules, Historical Calculation Name

Name the element and define its basic parameters.

Historical Rules - Processing Period

GP_HIST_RULE1

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Historical Rules, Processing Period

Define the details of the processing period for the historical rule. Depending on what you select as the rule type, some fields may not be available for entry.

Parameters and Mapping

GP_HIST_RULE2

Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Historical Rules, Parameters and Mapping

Define the formula for a historical rule.

Click to jump to top of pageClick to jump to parent topicNaming Historical Rule Elements

Access the Historical Calculation Name page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Historical Rules, Historical Calculation Name).

Note. You name every element and define its basic parameters on an element name page with the object name of GP_PIN. The page title and general appearance of this page change based on the type of Global Payroll element that you are naming and defining. All of the fields on this page are documented in another chapter in this PeopleBook.

See Also

Defining Element Names

Click to jump to top of pageClick to jump to parent topicDefining the Rule Type and Periods to Be Processed

Access the Historical Rules - Processing Period page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Historical Rules, Processing Period).

Note. On the Processing Period page, you create the periods from the date from to the date to date. You then map the selected result data to the processing periods. If no data exists for an element in a period, it is set to spaces for character and date elements and to zeros for numeric and monetary elements.

Rule Type

Select the type of historical rule from these options:

Use in Fictitious Calculation: Select when you want to use a historical rule element in a fictitious calculation element to determine which pay periods to recalculate.

Retrieve Values: Select when you want to use a historical rule element in a formula to retrieve previously calculated values.

Go back from Date Range

Define the date from, date to type, date from element, and date to element to establish the rule's date range. If you select a Retrieve Values rule type, this field appears as Go Back From Date Range. If you select a Use in Fictitious Calculation rule type, this field appears as Go Forward From Date Range.

Select from the following values in the Date From Type and Date To Type fields:

Bracket

Cal Date (calendar date): Enter a date instead of an element that resolves to a date. In the next field, specify the date to start going back from (for historical rules) or to start going forward from (for fictitious rules).

Date

Formula

SystemElem (system element)

Variable

Use Based On

Select a date that tells the system which data values from the GP_RSLT tables are processed by a historical rule. Select from these values: Period End Date, Period Begin Date or Payment Date.

Log statement at run time

Select this check box to see the text of the SQL statement dynamically generated by the array module during batch processing. You can direct the output display into a file by selecting the Redirect Output option in PeopleTools Configuration Manager.

Example

You want to determine three months of salary (element SALARY) for the period between March 28 and June 27. This table lists the GP_RSLT table values:

Period Payment Date

Result

Period Begin

Period End Date

Payment Date

January 2003

100

January 1, 2003

January 31, 2003

February 2, 2003

February 2003

100

February 1, 2003

February 28, 2003

March 2, 2003

March 2003

100

March 1, 2003

March 31, 2003

April 2, 2003

April 2003

100

April 1, 2003

April 30, 2003

May 2, 2003

May 2003

100

May 1, 2003

May 31, 2003

June 2, 2003

June 2003

100

June 1, 2003

June 30, 2003

July 2, 2003

July 2003

100

July 1, 2003

July 31, 2003

August 2, 2003

If you select Period Begin Date, the historical rule processes only June, May, and April. It does not process July, because July 1, 2003 (the period begin date) is later than the date from date of the historical period (June 27, 2003). It also does not process March, because March 1, 2003 (the period begin date) is before the date to date of the historical period (March 28, 2003).

Note. Historical rules start from the date from date and look at periods and segments in the reverse order in which they were originally processed and go back to the date to date.

If you select Period End Date, the rule processes May, April, and March. It does not process June, because June 30, 2003 (the period end date) is later than the date from date of the historical period (June 27, 2003). It also does not process February, because February 28, 2003 (the period end date) is before the date to date of the historical period (March 28, 2003).

If you select Payment Date, the rule processes May, April, and March. It does not process June, because July 2, 2003 (the payment date) is later than the date from date of the historical period (June 27, 2003). It also does not process February, because March 2, 2003 (the payment date) is before the date to date of the historical period (March 28, 2003).

See Also

Defining Segmentation

PeopleTools: Data Management PeopleBook

Click to jump to top of pageClick to jump to parent topicDefining the Formula for a Historical Rule Element

Access the Parameters and Mapping page (Set Up HRMS, Product Related, Global Payroll & Absence Mgmt, Elements, Supporting Elements, Historical Rules, Parameters and Mapping).

Note. Depending on whether you specified a historical or fictitious rule type on the Processing Period page, different fields appear on this page.

When you run a payroll, the system resolves the Formula to Execute by Segment field per historical period until the Stop Process If True variable is not equal to zero or the last historical period is processed. The system then resolves the formula specified in the Formula To Execute at End field.

Formula to Execute By Segment

Enter the formula to be resolved for each segment or period.

Stop Process If True

Enter a variable. The process keeps looping through periods, resolving the formula for each period, until this variable doesn't equal zero, the date to date is reached, or no more data is found.

Formula To Execute At End

Select the formula to resolve when period processing is completed.

Use Period If True

This field appears for Use in Fictitious Calculation rule types only. Enter a variable. After each call to the Formula to Execute By Segment field, this variable is checked for zero or one. If it's set to one, the fictitious calculation process uses the period for which the formula was called.

Element Mapping

The grid in the Element Mapping group box lists the elements for retrieval from the Global Payroll result tables for a historical rule.

Element Type

Select the type of element—such as the earning, deduction, or variable—to retrieve.

Historical Period Element

Enter the element that you want to retrieve.

Current Period Element

Enter the variable in which the retrieved value is to be stored. This variable becomes available for use in the Formula to Execute By Segment field.

Slice Option

Specify how the system resolves multiple instances of an element in the historical period. Values are:

  • Sum Slices:The system sums all slices.

  • Use Last Slice:The system uses the value of only the last slice.

  • Sum Slices - Current Empl Rcd:The system sums all slices, but only for rows of data where the EMPL_RCD equals the current EMPL_RCD.

  • Use Last Slice - Cur. Empl Rcd:The system uses the value of only the last slice, but only for rows of data where the EMPL_RCD equals the current EMPL_RCD.