Search Results test_crp_planner




Overview

APPS.MSC_VALID_PLAN_PKG is a validation utility package in the Oracle E-Business Suite Advanced Supply Chain Planning (ASCP) module. Its documented purpose is to evaluate whether a given plan definition in the MSC_PLANS repository is valid for a specific planning operation, based on the operation type being requested and the characteristics of the plan itself. The package acts as a gatekeeper: before ASCP, Material Requirements Planning (MRP), or Capacity Requirements Planning (CRP) engines are launched against a plan, calling code invokes MSC_VALID_PLAN to confirm that the plan is eligible for the requested processing mode. This prevents invalid plan launches that would otherwise fail deep inside the planning engine, consuming resources and generating ambiguous errors.

Key Procedures and Functions

The package body exposes a single documented public routine:

  • MSC_VALID_PLAN — The sole documented procedure. It receives arguments identifying the target plan and a set of flags describing the intended processing context: an exploder flag, a snapshot flag, a planner flag, and a CRP planner flag. Internally, the routine maps each flag to a numeric test level using named constants (TEST_EXPLODE, TEST_MRP_SNAPSHOT, TEST_PLANNER, TEST_CRP_PLANNER) and accumulates them into a composite test level. It then decomposes that level, in descending order of the constant values, into SYS_YES/SYS_NO indicators held in local variables (var_test_explode, var_test_snapshot, var_test_planner, var_test_crp_planner). It fetches the target plan row into an msc_plans%ROWTYPE record and raises a declared invalid_arg or invalid_plan exception when the arguments or the plan state fail validation. The procedure therefore returns no result set; callers detect failure through the raised exceptions.

Tables Accessed

The package references a single documented table through its APPS synonym:

  • MSC_PLANS — The master plan definition table. The package declares a record of type msc_plans%ROWTYPE (var_plan_rec), indicating a row-level read of the plan header. Attributes such as the plan's exploder eligibility, snapshot configuration, planner assignment, and CRP planner assignment are compared against the requested test flags to decide whether the plan may be launched for the supplied operation.

Usage Notes

MSC_VALID_PLAN is an internal validation API rather than an end-user function. It is typically invoked by other ASCP / MRP / CRP packages immediately prior to plan execution, and the ETRM metadata confirms it is referenced by one other package. Documented design notes are as follows:

  • In Oracle EBS 12.1.1 and 12.2.2 the package resides in the APPS schema and is classified as an OTHER API, meaning it is not a public, supported extension point and Oracle does not guarantee its signature across patches.
  • Custom code should not call it directly; the supported route for validating or launching a plan is through the standard planning concurrent programs and their submission forms.
  • The internal bit-flag arithmetic (constants valued 1, 2, 4, and 16) means the procedure is sensitive to the exact string values 'Y' passed for each argument; any other value is treated as a negative flag.
  • The header comment identifies the source file as MSCPVPDB.pls; a user's search for "test_explode" maps to the TEST_EXPLODE constant declared at line 14, which controls whether the plan is validated for an explode-type run.