Search Results delete_stages
Overview
APPS.AHL_VWP_VISITS_STAGES_PVT is a private PL/SQL package that supports the Visit Work Package (VWP) planning functionality within Oracle E-Business Suite's Complex Maintenance, Repair and Overhaul (CMRO) module. It manages the STAGES tier of the Planning → Visit Work Package → Visits → Stages hierarchy, providing the transactional logic that creates, updates, copies, validates, and closes visit stages and their associated stage rules and stage-type associations.
The package is classified as PVT (private), meaning it is an internal implementation layer not intended for direct customer invocation. It was originally created in the 11.5.10 code line (header tag AHLVSTGS.pls, version 120.0) and remains available in both 12.1.1 and 12.2.2. Its declared cursor-level procedures include Process_Visit, Get_Visit_Details, Create_Visit, Copy_Visit, Update_Visit, Delete_Visit, UMP_Visit_Info, and Close_Visit, which together constitute the visit lifecycle API surface used by the Visit Work Package UI. The ETRM 12.2.2 metadata documents 16 callable units, including the "process_visit" search term mapped to stage-level processing routines such as PROCESS_STAGETYP_ASSOC and the stage validation routines driven during a visit's processing.
Key Procedures and Functions
- UPDATE_STAGES — Modifies existing stage records for a visit, including stage name, duration, and planned start/end times, honoring object version concurrency.
- GET_STAGES_DETAILS — Retrieves stage attributes for a given visit or stage identifier for display or downstream processing.
- CREATE_STAGES — Inserts new stage rows into the visit structure, typically generated from a visit type's stage template.
- DELETE_STAGES — Removes specified stage records belonging to a visit.
- DELETE_ALL_STAGES — Clears every stage associated with a visit, used when regenerating a visit plan.
- VALIDATE_STAGE_UPDATES — Checks whether proposed stage changes are permissible, including hierarchy and rule constraints.
- CHECK_STAGE_NAME_OR_ID — Verifies uniqueness or existence of a stage name or identifier before insert or update.
- PROCESS_STAGETYP_ASSOC — Processes associations between stages and stage types, driving the stage-type assignment logic invoked during visit processing.
- VALIDATE_STAGE_RULES — Evaluates stage rule definitions to confirm sequencing and dependency compliance.
- ASSOC_VISITTYPE_TO_VISIT — Links a visit type definition to a visit instance so its stage structure can be applied.
- GET_VISIT_STAGE_NUMBER — Derives the sequential stage number assigned within a visit.
- UPDATE_STAGES_HIERARICHY — Maintains stage hierarchy relationships when stages are reordered or nested.
- UPDATE_STG_RUL_HIERARCHY — Maintains hierarchy for stage rules corresponding to stage structure changes.
- UPDATE_AS_STAGE_RULE_DEL — Handles stage-rule deletion cascades and constraint cleanup.
- VALIDATE_STAGE_DATES — Confirms planned stage dates fall within allowable visit and shift windows.
- COMPUTE_STAGE_END_DATE — Calculates stage end dates from duration and shift calendar data.
Tables Accessed
- AHL_VWP_STAGES_B — Base table holding visit stage definitions; primary read/write target.
- AHL_VISITS_B — Parent visit records against which stages are organized.
- AHL_VISIT_TYPES_B, AHL_VISIT_TYPE_STAGES_B — Visit type and its stage templates used when generating stages.
- AHL_VISIT_STAGE_TYP_ASOC, AHL_VISIT_STAGE_TYP_ASOC_S — Stage-to-stage-type association records processed by PROCESS_STAGETYP_ASSOC.
- AHL_VST_TYP_STAGE_LINKS, AHL_VST_TYP_STG_TYP_ASOC — Link tables defining visit-type stage hierarchies and stage-type associations.
- AHL_STAGE_LINKS, AHL_STAGE_LINKS_S — Store stage-to-stage dependency and rule links used in rule validation and hierarchy updates.
- AHL_TASK_LINKS, AHL_VISIT_TASKS_B — Task relationships referenced when validating stage/task sequencing.
- AHL_DEPARTMENT_SHIFTS — Shift calendars used by COMPUTE_STAGE_END_DATE and VALIDATE_STAGE_DATES.
- AHL_MC_HEADERS_B, AHL_UNIT_CONFIG_HEADERS — Maintenance context headers linked to the visit for constraint checks.
Usage Notes
AHL_VWP_VISITS_STAGES_PVT is invoked exclusively through Oracle Forms and other server-side packages; it is not exposed as a concurrent program entry point. The Visit Work Package planning form calls these procedures when a user creates or edits stages, reassigns visit types, or triggers visit processing. Nine other packages reference this package, confirming it as an internal service consumed by the public VWP visit APIs and stage-handling logic rather than by custom extensions. Because it is private, customers should not call it directly; changes to stage data should be performed through the supported Visit Work Package UI or public APIs. Its presence in both 12.1.1 and 12.2.2 keeps the stage-management logic consistent across the two releases.
-
APPS.AHL_VWP_VISITS_STAGES_PVT SQL Statements
12.1.1
-
APPS.AHL_VWP_VISITS_STAGES_PVT_W SQL Statements
12.2.2
-
PACKAGE: APPS.AHL_VWP_VISITS_STAGES_PVT
12.1.1
-
PACKAGE BODY: APPS.AHL_VWP_VISITS_STAGES_PVT
12.1.1
-
APPS.AHL_VWP_VISITS_STAGES_PVT SQL Statements
12.2.2
-
PACKAGE: APPS.AHL_VWP_VISITS_STAGES_PVT
12.2.2
-
PACKAGE: APPS.AHL_VWP_VISITS_STAGES_PVT_W
12.2.2
-
PACKAGE BODY: APPS.AHL_VWP_VISITS_STAGES_PVT
12.2.2
-
APPS.AHL_VWP_VISITS_STAGES_PVT dependencies on FND_MSG_PUB
12.1.1
-
PACKAGE BODY: APPS.AHL_VWP_VISITS_STAGES_PVT_W
12.2.2
-
APPS.AHL_VWP_VISITS_PVT dependencies on AHL_CMP_UTIL_PKG
12.2.2
-
APPS.AHL_VWP_VISITS_STAGES_PVT dependencies on FND_API
12.1.1
-
APPS.AHL_VWP_VISITS_STAGES_PVT dependencies on FND_API
12.1.1
-
APPS.AHL_VWP_VISITS_STAGES_PVT dependencies on AHL_DEBUG_PUB
12.1.1
-
APPS.AHL_VWP_VISITS_PVT dependencies on AHL_VWP_VISITS_STAGES_PVT
12.2.2
-
APPS.AHL_VWP_VISITS_STAGES_PVT dependencies on FND_API
12.2.2
-
APPS.AHL_VWP_VISITS_STAGES_PVT dependencies on FND_MSG_PUB
12.2.2
-
APPS.AHL_VWP_VISITS_STAGES_PVT dependencies on FND_API
12.2.2
-
PACKAGE BODY: APPS.AHL_VWP_VISITS_PVT
12.2.2
-
APPS.AHL_VWP_VISITS_STAGES_PVT dependencies on FND_LOG
12.2.2
-
APPS.AHL_VWP_VISITS_PVT dependencies on FND_LOG
12.2.2