Payroll Relationship Group Formula Type

The Payroll Relationship Group formula type returns Yes or No to indicate whether a person is part of a payroll relationship group. The formula contains the criteria that define the group.

You can use these groups to define a set of people for payroll processing, data entry, or reporting. On the Object Groups page, select the formula when creating a payroll relationship group.

For example, you can use the Payroll Relationship Group formula type to restrict the payroll run process to a specific set of employees based on assignment and person-level attributes.

By default, you create formulas of this type using the Expression editor on the Create Fast Formula page. However, you can use the text editor to create more complex formulas, if required.

These contexts are available to all formulas of this type:

  • PAYROLL_RELATIONSHIP_ID

  • PAYROLL_TERM_ID

  • DATE_EARNED

  • OBJECT_GROUP_ID

  • EFFECTIVE_DATE

  • PAYROLL_ASSIGNMENT_ID

  • PAYROLL_ID

  • LEGISLATIVE_DATA_GROUP_ID

You must have at least one input value called LEVEL_NAME. The data type is text and these are the valid values:

  • PAY_REL

  • PAY_TERM

  • PAY_ASG

This return value is available to the INCLUDE_FLAG formula type. The data type is text.

This formula calls the summary formula for each of the levels in the person group until the membership is established.

*/
DEFAULT_DATA_VALUE FOR PERSON_GROUP_LEVEL_SUMMARY_FORMULA_NAME is 'null' 
NEED_CONTEXT(PAYROLL_RELATIONSHIP_ID)NEED_CONTEXT(PAYROLL_TERM_ID)
NEED_CONTEXT(PAYROLL_ASSIGNMENT_ID)
NEED_CONTEXT(LEGISLATIVE_DATA_GROUP_ID)
NEED_CONTEXT(PAYROLL_ID)NEED_CONTEXT(DATE_EARNED)
NEED_CONTEXT(EFFECTIVE_DATE)

in_group = 'N'

SET_INPUT('level_name', 'PAY_REL')
EXECUTE (PERSON_GROUP_LEVEL_SUMMARY_FORMULA_NAME[1])
in_group = GET_OUTPUT('INCLUDE_FLAG', 'N')

IF (in_group = 'N') THEN
(
SET_INPUT('level_name', 'PAY_TERM')
EXECUTE (PERSON_GROUP_LEVEL_SUMMARY_FORMULA_NAME[1])
in_group = GET_OUTPUT('INCLUDE_FLAG', 'N')
)
IF (in_group = 'N') THEN(SET_INPUT('level_name', 'PAY_ASG')
EXECUTE (PERSON_GROUP_LEVEL_SUMMARY_FORMULA_NAME[1])
in_group = GET_OUTPUT('INCLUDE_FLAG', 'N')
)IF in_group = 'Y' THEN 
INCLUDE_FLAG = 'Y' 

RETURN INCLUDE_FLAG