Search Results check_compliance




Overview

QPR_DEAL_APPROVALS_PVT is a private PL/SQL package in the Oracle E-Business Suite (EBS) Applications (APPS) schema. It belongs to the Oracle Trade Management / Quoting module and provides the underlying approval engine for deal and quote approval workflows. The package name follows Oracle's convention: the QPR prefix identifies the Quoting/Deal Management product family, and the _PVT suffix indicates that the package is intended for internal use rather than as a public API. The package is declared with AUTHID CURRENT_USER, meaning it executes with the privileges of the calling schema rather than the definer.

Its principal business function is to determine whether a deal, quote, or negotiation response requires approvals, to drive the approval routing that ensues, and to process the actions taken by approvers. It supports both interactive use through Oracle Forms and headless invocation from other packages and concurrent programs, as evidenced by the p_standalone_call parameter present on the process_user_action overloads.

Key Procedures and Functions

The package exposes seven documented program units:

  • INIT_APPROVALS — Initialises the approval process for a given response header, evaluating the applicable approval rules and creating the approval records required for the response.
  • CHECK_COMPLIANCE — Evaluates a response header against compliance criteria and returns whether the response complies along with a description of the rules that were applied.
  • PROCESS_USER_ACTION — The central procedure for this package. Two overloads are provided: one keyed by numeric user ID and one keyed by user name. Both accept a response header identifier, an action code, and comments, and both return an indicator of whether approvals are complete together with a return status. An optional standalone-call flag differentiates programmatic invocation from form-driven invocation.
  • SYNCH_APPROVALS — Synchronises the approval state between an original response and a newly created response, used when a revised response must inherit or realign the approval position of its predecessor.
  • PROCESS_STUCK_NOTIFICATIONS — Repairs or advances approval notifications that have become stalled, re-driving the workflow so that pending approvers are not left with orphaned notifications.
  • CLEAR_ACTION_HISTORY — Removes prior action history for a response, user, and action code combination, typically invoked before re-initialising an approval cycle.

Tables Accessed

The package reads and writes the following tables through APPS synonyms:

  • QPR_PN_RESPONSE_APPROVALS and QPR_PN_RESPONSE_APPROVALS_S — the approval and approval-history tables where approver assignments and actions are recorded.
  • QPR_PN_RESPONSE_HDRS — the response/negotiation header that identifies the deal or quote being approved.
  • FND_USER — used to resolve user identity between the numeric user ID and user name overloads of process_user_action.
  • FND_APPLICATION — used for application context and product identification.
  • DUAL and PLITBLM — standard utility constructs for single-row selection and PL/SQL table handling.

Usage Notes

Because the package is classified PVT, it is not supported for direct customer invocation; Oracle reserves the right to change its signature without notice. In practice it is invoked from Oracle Forms attached to the Trade Management deal and quote screens when an approver submits a decision, from workflow notification callbacks, and from other packages in the approval stack — the metadata records two dependent packages. Programmatic callers should pass the standalone-call flag as true so that internal assumptions about the calling context are honoured. For custom development, Oracle recommends using the public approval APIs rather than calling QPR_DEAL_APPROVALS_PVT directly.