Search Results terr_qual_trigger_handler
Overview
The APPS.JTY_TERR_TRIGGER_HANDLERS package is a PL/SQL trigger handler API belonging to the Oracle E-Business Suite Territory Management (ETRM) module. It is declared with AUTHID CURRENT_USER, meaning it executes with the privileges of the calling user rather than its owner, which is significant for security-sensitive territory operations. Its stated purpose, per the embedded package header comments, is to define Territory Trigger handlers for the core territory tables — JTF_TERR, JTF_TERR_VALUES, JTF_TERR_RSC, JTF_TERR_RSC_ACCESS, JTF_TERR_QTYPE_USGS, and JTF_TERR_QUAL. The package encapsulates the business logic that must fire when territory data changes, allowing database triggers on the underlying territory tables to delegate their processing to a centralised, maintainable API rather than embedding logic in each trigger. The header history indicates the package was created by achanda on 25-Aug-2005, with the source revision comment dated 30-Mar-2006. It is referenced by seven other packages in the ETRM schema, confirming its role as a shared dependency for territory-change propagation.
Key Procedures and Functions
The package exposes seven documented procedures, each acting as a handler for a specific triggering context:
- TERRITORY_TRIGGER_HANDLER — the principal handler for changes to the territory definition itself. It captures old and new values of territory attributes such as parent territory, active date range, rank, number of winners, and the named-account flag, together with a triggering mode parameter. This allows downstream logic to compare prior and current state and propagate changes accordingly.
- TERR_VALUES_TRIGGER_HANDLER — handles changes relating to territory values, keyed by a territory qualification identifier. This is the procedure most directly associated with the user search term terr_values_trigger_handler.
- TERR_RSC_TRIGGER_HANDLER — responds to changes in territory resources, keyed by territory identifier.
- TERR_QTYPE_TRIGGER_HANDLER — responds to changes in territory qualification-type usage, keyed by territory identifier.
- TERR_RSCACCESS_TRIGGER_HANDLER — responds to changes in territory resource access records, keyed by territory resource identifier.
- TERR_QUAL_TRIGGER_HANDLER — responds to changes in territory qualification records, keyed by territory identifier.
- TERR_USGS_TRIGGER_HANDLER — responds to territory usage changes, accepting a territory identifier, a source identifier, and a triggering mode indicator.
All procedures are declared for external invocation; the package specification does not document return values, indicating these are procedural handlers rather than query functions.
Tables Accessed
The metadata lists the following objects referenced through APPS synonyms: JTF_TERR_QUAL, JTF_TERR_RSC_ALL, JTF_TERR_USGS_ALL, JTY_CHANGED_DEA_TERRS, JTY_CHANGED_DEA_TERRS_S, JTY_CHANGED_TERRS, JTY_CHANGED_TERRS_S, and DUAL. The JTF_TERR_* tables hold the master territory definition, qualification, resource, and usage data whose changes the handlers respond to. The JTY_CHANGED_TERRS and JTY_CHANGED_DEA_TERRS tables (with their _S sequence objects) serve as staging or queue tables recording territories that have changed, enabling deferred or batched reprocessing — particularly relevant in Denied-Entity/Account (DEA) territory scenarios. DUAL is used for singleton evaluations within the handler logic.
Usage Notes
This package is designed to be invoked from database triggers attached to the JTF territory tables, passing the relevant primary key and a triggering mode. Because the territory assigner and related ETRM processing depend on accurate change tracking, the handlers typically enqueue affected territory identifiers into the JTY_CHANGED_TERRS family of tables for subsequent processing by the Territory Assignment concurrent program. Customisations should not call these procedures directly unless replicating the exact trigger semantics, as the handlers assume a specific triggering mode and key context. Developers extending territory functionality should treat this package as a foundational API and review the seven dependent packages before modifying behaviour.
-
PACKAGE: APPS.JTY_TERR_TRIGGER_HANDLERS
12.2.2
-
PACKAGE: APPS.JTY_TERR_TRIGGER_HANDLERS
12.1.1
-
PACKAGE BODY: APPS.JTY_TERR_TRIGGER_HANDLERS
12.1.1
-
PACKAGE BODY: APPS.JTY_TERR_TRIGGER_HANDLERS
12.2.2
-
APPS.JTY_TERR_TRIGGER_HANDLERS dependencies on JTF_TERR_QUAL
12.1.1
-
APPS.JTY_TERR_TRIGGER_HANDLERS dependencies on JTF_TERR_QUAL
12.2.2
-
APPS.JTY_TERR_TRIGGER_HANDLERS dependencies on FND_MSG_PUB
12.2.2
-
APPS.JTY_TERR_TRIGGER_HANDLERS dependencies on FND_MSG_PUB
12.1.1