Search Results add_to_batch
Overview
APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE is an Oracle E-Business Suite payroll-side interface package that bridges Oracle Time and Labor (OTL) retrieval data with Oracle Payroll batch processing. Its principal business function is to consolidate timecard and retrieval information originating from the HXC (Oracle Time and Labor) schema into the PAY_BATCH_HEADERS and PAY_BATCH_LINES structures so that payroll runs can process the resulting elements, including adjustments, retroactive entries, and BEE (Batch Element Entry) transactions. In effect, the package acts as a batch loader and converter, transforming OTL transactions and building blocks into payroll batch lines that payroll costing and processing can consume.
The header comment identifies the source file as pytshpri.pkb (version 120.8), confirming that the package is part of the standard payroll time-and-labor integration delivered in EBS 12.1.1 and 12.2.2. The package operates on a global package name (pay_hr_otc_retrieval_interface.), declares standard global exceptions (e_continue, e_halt), and maintains state such as g_batches_created and a g_retro_batch_suffix constant defaulting to '_RETRO'. A display_value function converts internal LOV codes to their displayed meanings by joining PAY_INPUT_VALUES_F and PAY_ELEMENT_TYPES_F.
Key Procedures and Functions
The documented API surface contains twenty procedures and functions, which fall into several logical groups:
- RETRO_BATCH_SUFFIX / SET_RETRO_BATCH_SUFFIX — retrieve and set the suffix appended to retroactive batch names, defaulting to
_RETRO. - RECORD_BATCH_INFO / BATCHES_CREATED / BATCH_NAME — maintain and expose the table of batches generated during a run (
batches_type_table), populating the in-memory record set and returning batch names. - CREATE_BATCH_HEADER / ADD_TO_BATCH / BEE_BATCH_LINE — create header records in PAY_BATCH_HEADERS and append individual lines to PAY_BATCH_LINES.
ADD_TO_BATCHis the routine most commonly referenced when custom code or diagnostics need to append a line to the currently active batch. - WHERE_CLAUSE — builds a dynamic SQL predicate used to select the appropriate assignment or element population for a run.
- PROCESS_OTLR_EMPLOYEES / EXTRACT_DATA_FROM_ATTR_TBL — drive the main retrieval processing loop over OTL employees and extract attribute data from the time attribute table.
- TRANSFER_TO_HR_PAYROLL — the principal orchestration routine that moves extracted data into HR/Payroll batch structures.
- MAKE_ADJUSTMENTS_BEE / MAKE_ADJUSTMENTS_OTM — generate adjustment entries for BEE and OTM (Oracle Time and Labor module) scenarios.
- RECORD_PAY_PA_DETAILS — persists Payroll/Project Accounting linkage details.
- CACHE_PREFERENCES / CHK_INTG_ENABLED — cache configuration preferences and validate that integration with the target application is enabled.
- MARK_BATCHES_FOR_ROLLBACK — flags created batches so they can be rolled back if processing fails.
Tables Accessed
The package references the following tables through APPS synonyms:
- PAY_BATCH_HEADERS / PAY_BATCH_LINES — the primary write targets; batch headers and element entry lines are inserted here.
- HXC_RETRIEVAL_PROCESSES, HXC_TRANSACTIONS, HXC_TIME_BUILDING_BLOCKS — OTL sources read to obtain timecard and retrieval data.
- HXC_PAY_PA_LINK_ALL — provides the OTL-to-Payroll/Project Accounting mapping used by RECORD_PAY_PA_DETAILS.
- PAY_ELEMENT_TYPES_F, PER_ALL_ASSIGNMENTS_F, PER_ALL_PEOPLE_F — element and assignment/person validation and lookup.
- HR_ALL_ORGANIZATION_UNITS, HR_SOFT_CODING_KEYFLEX — business group and soft coding key flexfield resolution.
- FND_APPLICATION, FND_NEW_MESSAGES, FND_CONCURRENT_REQUESTS, FND_FLEX_VALUES — application context, error messaging, concurrent request context, and flex value lookups.
Usage Notes
PAY_HR_OTC_RETRIEVAL_INTERFACE is invoked indirectly through Oracle Payroll and Oracle Time and Labor retrieval concurrent programs rather than directly by end users. The package is referenced by zero other PL/SQL packages in the ETRM catalog, indicating it is a terminal consumer called from concurrent program definitions and form-driven retrieval flows. Customizations should not call the internal procedures directly where a supported concurrent program exists, but diagnostic or extension code may legitimately reference ADD_TO_BATCH, BATCH_NAME, and BATCHES_CREATED when auditing or extending batch generation. Because the package writes to PAY_BATCH_HEADERS and PAY_BATCH_LINES, any direct invocation must respect batch rollback semantics via MARK_BATCHES_FOR_ROLLBACK to avoid orphaned or duplicate batch lines. Integration must be enabled (validated by CHK_INTG_ENABLED) before OTL data is transferred to HR/Payroll.
-
PACKAGE BODY: APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE
12.1.1
-
PACKAGE: APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE
12.1.1
-
PACKAGE: APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE
12.2.2
-
PACKAGE BODY: APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE
12.2.2
-
APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE dependencies on PAY_BATCH_LINES
12.1.1
-
APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE dependencies on PAY_BATCH_LINES
12.2.2
-
APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE dependencies on PAY_BATCH_HEADERS
12.2.2
-
APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE dependencies on PAY_BATCH_HEADERS
12.1.1
-
APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE dependencies on PAY_BATCH_HEADERS
12.2.2
-
APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE dependencies on PAY_BATCH_HEADERS
12.1.1
-
APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE dependencies on PAY_BATCH_LINES
12.2.2
-
APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE dependencies on PAY_BATCH_LINES
12.1.1
-
APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE dependencies on HR_UTILITY
12.1.1
-
APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE dependencies on HXT_INTERFACE_UTILITIES
12.1.1
-
APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE dependencies on HXT_INTERFACE_UTILITIES
12.2.2
-
APPS.PAY_HR_OTC_RETRIEVAL_INTERFACE dependencies on HR_UTILITY
12.2.2