Professional Documents
Culture Documents
Global Payroll Using Payroll Relationship Group To Dynamically Mark For Retry
Global Payroll Using Payroll Relationship Group To Dynamically Mark For Retry
AUGUST 3, 2020
`
DISCLAIMER
The following is intended to outline our general product direction. It is intended for information
purposes only, and may not be incorporated into any contract. It is not a commitment to deliver any
material, code, or functionality, and should not be relied upon in making purchasing decisions. The
development, release, and timing of any features or functionality described for Oracle’s products
remains at the sole discretion of Oracle.
Oracle Fusion Human Capital Management for Global Payroll: Using Payroll Relationship Group to Dynamically Mark for Retry Page 2
`
Table of Contents
Table of Contents
Introduction ..................................................................................................4
Appendices ..................................................................................................9
Appendix II SQL for Marked for Retry payroll relationships by payroll calculation flow name .... 10
Appendix III SQL for distribution of Complete, Error, Marked for Retry actions for payroll
calculation flow name ................................................................................................................ 10
Oracle Fusion Human Capital Management for Global Payroll: Using Payroll Relationship Group to Dynamically Mark for Retry Page 3
`
INTRODUCTION
The ability to respond to changes to processed employees from within the payroll processing
window without having to rollback or retry the whole employee population is essential to payroll
processing. Marking employees individually for retry requiring large scale changes, such as late
time loads, is not practical so dynamically determining records to be marked for retry and
automatically marking them for retry makes payroll processing more efficient.
The Mark for Retry process recognizes the dynamic Payroll Relationship Object Group as a
parameter to dynamically identify individual employees. Using a dynamic payroll relationship object
group, employees who have had changes to their element entries since payroll has been run can be
determined dynamically and be automatically marked for retry.
Using SQL to dynamically generate values in a table validated value set, the Payroll Relationship
Group Formula can access element entry and element entry value events. The timing of these
events are compared to the original execution time of the payroll run for the employee to determine
if they should be marked for retry. This comparison determines whether or not the payroll
relationship is included in the list valid payroll relationships.
Refer to the two SQL statements provided in the Appendices to show by payroll calculation flow
name i) the payroll relationships currently marked for retry and ii) the overall distribution of
Complete, Error, Marked for Retry payroll relationships.
Oracle Fusion Human Capital Management for Global Payroll: Using Payroll Relationship Group to Dynamically Mark for Retry Page 4
`
EXISTS
( SELECT 'ppa'
FROM pay_payroll_actions ppa
, pay_payroll_rel_actions pra
Oracle Fusion Human Capital Management for Global Payroll: Using Payroll Relationship Group to Dynamically Mark for Retry Page 5
`
, pay_time_periods ptp
WHERE
ppa.action_type = 'R' AND
ppa.action_status = 'C' AND
ppa.payroll_action_id = TO_NUMBER(:{PARAMETER.P_PAYROLL_ACTION_ID}) AND
pra.payroll_action_id = ppa.payroll_action_id AND
pra.payroll_relationship_id = TO_NUMBER(:{PARAMETER.P_PAYROLL_RELATIONSHIP_ID}) AND
pra.source_action_id IS NULL AND
pra.action_status = 'C' AND
ptp.time_period_id = ppa.earn_time_period_id
AND EXISTS (
SELECT 'ee_event' event
FROM pay_process_events ppe,
pay_dated_tables pdt,
pay_element_entries_f ee
WHERE
ppe.payroll_relationship_id = pra.payroll_relationship_id AND
ppe.creation_date >= ppa.last_update_date AND
pdt.dated_table_id = ppe.dated_table_id AND
pdt.table_name = 'PAY_ELEMENT_ENTRIES_F' AND
ee.element_entry_id(+) = ppe.surrogate_key_id AND
NVL(ee.effective_start_date, ppe.calculation_date) <= ptp.end_date AND
NVL(ee.effective_end_date, ppe.calculation_date) >= ptp.start_date
UNION
SELECT 'eev_event' event
FROM pay_process_events ppe,
pay_dated_tables pdt,
pay_element_entries_f ee,
pay_element_entry_values_f eev
WHERE ppe.payroll_relationship_id = pra.payroll_relationship_id AND
ppe.creation_date >= ppa.last_update_date AND
pdt.dated_table_id = ppe.dated_table_id AND
pdt.table_name = 'PAY_ELEMENT_ENTRY_VALUES_F' AND
eev.element_entry_value_id(+) = ppe.surrogate_key_id AND
ee.element_entry_id(+) = eev.element_entry_id AND
NVL(ee.effective_start_date, ppe.calculation_date) <= ptp.end_date AND
NVL(ee.effective_end_date, ppe.calculation_date) >= ptp.start_date ))
Oracle Fusion Human Capital Management for Global Payroll: Using Payroll Relationship Group to Dynamically Mark for Retry Page 6
`
Note: This solution relies on a new PAYROLL_ACTION_ID context for the Payroll Relationship Group formula type, which is due to be
delivered in 18C and backported to 18B. The formula will generate the following compilation details error message if the context does
not exist in your environment.
Note: Once the fast formula has been created, it can be referenced in the Dynamic Payroll Relationship Group.
Oracle Fusion Human Capital Management for Global Payroll: Using Payroll Relationship Group to Dynamically Mark for Retry Page 7
`
Oracle Fusion Human Capital Management for Global Payroll: Using Payroll Relationship Group to Dynamically Mark for Retry Page 8
`
NOTE: Fast formulas cannot be edited when referenced in a Payroll Relationship Group. To edit, remove the formula from the group,
edit then reference from group.
APPENDICES
/* =============================================================
=============================================================*/
/* local variables */
lc_include_flag = 'N'
Oracle Fusion Human Capital Management for Global Payroll: Using Payroll Relationship Group to Dynamically Mark for Retry Page 9
`
ln_payroll_relationship_id = -1
ln_payroll_action_id = -1
lc_payroll_relationship_id = 'X'
lc_payroll_action_id = 'X'
lc_changes_exist = 'X'
IF ( lc_changes_exist = 'X' )
THEN
(
lc_include_flag = 'Y'
)
include_flag = lc_include_flag
RETURN include_flag
Appendix II SQL for Marked for Retry payroll relationships by payroll calculation flow name
Description: Returns the payroll relationships currently marked for retry by flow name
SELECT
rel.payroll_relationship_number
FROM
pay_pay_relationships_dn rel
, pay_payroll_rel_actions pra
, pay_payroll_actions pa
, pay_requests pr
, pay_flow_instances fi
WHERE
fi.instance_name = :flow_name
AND
pr.flow_instance_id = fi.flow_instance_id
AND
pa.pay_request_id = pr.pay_request_id
AND
pra.payroll_action_id = pa.payroll_action_id AND
pra.source_action_id IS NULL AND
pra.action_status = 'M'
AND
rel.payroll_relationship_id = pra.payroll_relationship_id
ORDER BY
rel.payroll_relationship_number
Appendix III SQL for distribution of Complete, Error, Marked for Retry actions for payroll calculation flow name
Description: Returns the overall distribution of Complete, Error and Marked for Retry payroll relationships by payroll flow name
SELECT
Oracle Fusion Human Capital Management for Global Payroll: Using Payroll Relationship Group to Dynamically Mark for Retry Page 10
`
count(*)
, lk_action_status.meaning
FROM
pay_payroll_rel_actions pra
, pay_payroll_actions pa
, hr_lookups lk_action_type
, hr_lookups lk_action_status
, pay_requests pr
, pay_flow_instances fi
WHERE
fi.instance_name = :flow_name
AND
pr.flow_instance_id = fi.flow_instance_id
AND
pa.pay_request_id = pr.pay_request_id AND
pa.action_type = 'R'
AND
pra.payroll_action_id = pa.payroll_action_id AND
pra.source_action_id IS NULL
AND
lk_action_type.lookup_type = 'ACTION_TYPE' AND
lk_action_type.lookup_code = pa.action_type
AND
lk_action_status.lookup_type = 'PAY_ACTION_STATUS' AND
lk_action_status.lookup_code = pra.action_status
group by
lk_action_status.meaning
Oracle Fusion Human Capital Management for Global Payroll: Using Payroll Relationship Group to Dynamically Mark for Retry Page 11
ORACLE CORPORATION
Worldwide Headquarters
500 Oracle Parkway, Redwood Shores, CA 94065 USA
Worldwide Inquiries
TELE + 1.650.506.7000 + 1.800.ORACLE1
FAX + 1.650.506.7200
oracle.com
CONNECT WITH US
Call +1.800.ORACLE1 or visit oracle.com. Outside North America, find your local office at oracle.com/contact.
Copyright © 2020, Oracle and/or its affiliates. All rights reserved. This document is provided for information purposes only, and the contents hereof are
subject to change without notice. This document is not warranted to be error-free, nor subject to any other warranties or conditions, whether expressed
orally or implied in law, including implied warranties and conditions of merchantability or fitness for a particular purpose. We specifically disclaim any
liability with respect to this document, and no contractual obligations are formed either directly or indirectly by this document. This document may not be
reproduced or transmitted in any form or by any means, electronic or mechanical, for any purpose, without our prior written permission.
Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners.
Intel and Intel Xeon are trademarks or registered trademarks of Intel Corporation. All SPARC trademarks are used under license and are trademarks or
registered trademarks of SPARC International, Inc. AMD, Opteron, the AMD logo, and the AMD Opteron logo are trademarks or registered trademarks
of Advanced Micro Devices. UNIX is a registered trademark of The Open Group. 0820
Oracle Fusion Human Capital Management for Global Payroll: Using Payroll Relationship Group to Dynamically Mark for Retry
August 2020