Search Results element_task_map
Overview
APPS.PA_FP_COPY_FROM_PKG is a financial planning (FP) utility package in Oracle E-Business Suite Projects (PA). Its business purpose is to copy budget and financial plan structures from a source project or budget version into a target, supporting workflows such as copying a project template's plan, duplicating a budget version, or propagating plan setup when a workplan (WP) or work breakdown structure is copied. The package is classified as OTHER in ETRM, meaning it is not a formally published public API, but it is referenced by ten other packages, which confirms its role as an internal workhorse for plan duplication logic.
The package body is identified as PAFPCPFB.pls, version 120.20.12010000.2 (last shipped 2008/09/10), and is compatible with EBS 12.1.1 and 12.2.2. A notable historical change documented in the header is the removal of Multi-Report Currency (MRC) code under Bug Fix 4569365, so the package does not perform MRC-related conversions. It defines arrays sized by the global g_plsql_max_array_size (default 200) and mapping constants ELEMENT_TASK_MAP and ELEMENT_ELEMENT_MAP (Bug 3354518).
Key Procedures and Functions
The package exposes sixteen documented procedures and functions, each handling a specific aspect of the copy operation:
- COPY_PLAN — primary entry point; orchestrates copying a complete financial plan from a source to a target plan version, including locking, budget versions, resources, lines, and periods.
- COPY_BUDGET_VERSION — copies header-level budget version definitions, including period profiles and option flags.
- COPY_BUDGETS_FROM_PROJECT — copies all budget versions and associated data from a source project to a target project.
- COPY_FINPLANS_FROM_PROJECT — copies financial plan versions across projects, supporting plan-level duplication.
- COPY_RESOURCE_ASSIGNMENTS — duplicates resource assignments (and their task associations) from source to target plan version.
- COPY_BUDGET_LINES — copies budget lines and their detail into the target version.
- COPY_BUDGET_LINES_APPR_REV — copies budget lines in the context of approved/reviewed workflow states.
- COPY_PERIODS_DENORM — rebuilds denormalized period data associated with the copied plan.
- COPY_CURRENT_PERIOD_PROFILES — copies period profile definitions that are current for the source plan.
- GET_CREATE_SHIFTED_PD_PROFILE — derives shifted period profiles when the target plan uses different period calendars or offsets.
- GET_FP_OPTIONS_TO_BE_COPIED — determines which PA_PROJ_FP_OPTIONS entries should be replicated.
- COPY_WP_BUDGET_VERSIONS — copies budget versions tied to workplan structures.
- CREATE_RES_TASK_MAPS — builds the resource-to-task mapping between source and target using the mapping constants.
- UPDATE_PLAN_SETUP_FOR_WP_COPY — the procedure most relevant to the user's search term; it updates plan-level setup attributes (such as option flags and period profile associations) on the target plan when a workplan is copied. It ensures the copied plan's setup is consistent with the newly created WP structure.
- ACQUIRE_LOCKS_FOR_COPY_ACTUAL and ACQUIRE_LOCKS_FOR_COPY_PLAN — acquire
FOR UPDATE NOWAITlocks on PA_PROJ_FP_OPTIONS and PA_BUDGET_VERSIONS to prevent concurrent modification during copy; aResource_Busyexception (-00054) is trapped and reported via standard return-status/msg-count/msg-data out parameters.
Tables Accessed
The package reads and writes the core Projects planning tables through APPS synonyms:
- PA_PROJ_FP_OPTIONS and PA_BUDGET_VERSIONS — plan and budget version headers; locked and copied.
- PA_BUDGET_LINES, PA_BUDGET_LINES_S — budget line detail and its descriptive/security rows.
- PA_FIN_PLAN_AMOUNT_SETS — amount sets linked to the plan version.
- PA_RESOURCE_ASSIGNMENTS — resource/task assignments duplicated for the target.
- PA_PROJ_ELEMENT_VERSIONS, PA_PROJ_PERIOD_PROFILES — element version and period profile definitions.
- PA_PROJECTS, PA_PROJECTS_ALL — project header context for copy operations.
- PA_PERIODS, GL_PERIODS, GL_PERIOD_STATUSES — period lookup and status validation.
- PA_TXN_ACCUM — accumulated transaction amounts used in plan/actual reconciliation.
- FND_USER — identifies the locking user for concurrency and auditing.
Usage Notes
PA_FP_COPY_FROM_PKG is not intended for direct customer invocation; it is normally called from Projects forms (such as the Financial Plan copy action) and from concurrent programs that duplicate budgets, plans, or workplan structures. Because it acquires row locks with FOR UPDATE NOWAIT, concurrent copy attempts raise a Resource_Busy condition and should be retried after the lock is released. Callers must honor the standard EBS out-parameter contract (x_return_status, x_msg_count, x_msg_data) and are advised to check FND_PROFILE.value('PA_DEBUG_MODE') for diagnostic output. Custom code should avoid calling internal procedures such as UPDATE_PLAN_SETUP_FOR_WP_COPY directly, as their signatures and behavior may change without public API notification; the supported recommendation is to invoke COPY_PLAN or the corresponding concurrent program.