PLS-00452: Subprogram Violates Its Associated Pragma - Undocumented Information
(Doc ID 376803.1)
Last updated on JANUARY 30, 2022
Applies to:
PL/SQL - Version 8.1.7.4 and laterInformation in this document applies to any platform.
Symptoms
Although this error can be seen in a number of different scenarios, the following describes just one scenario where this error unexpectedly occurs.
This scenario is where a View is created based on a Table. The View also has an column definition that is the result of a function call within a package. This package has multiple procedures and/or functions and each are unrelated to the other but happen to exist within the same package. Each function/procedure within the package has a different "PRAGMA RESTRICT_REFERENCES" purity level.
This package builds and executes without error.
When a new packaged function is created that references the View, it results in the following error even though the purity level of the new packaged function matches that of the package function used in the View.
LINE/COL ERROR
-------- -----------------------------------------------------------------
2/8 PLS-00452: Subprogram 'NEWFUNCTION' violates its associated pragma
For Example:
Sample Output:
SQL> show errors
Errors for PACKAGE BODY PACKAGE2:
LINE/COL ERROR
-------- -----------------------------------------------------------------
2/8 PLS-00452: Subprogram 'NEWFUNCTION' violates its associated pragma
Cause
To view full details, sign in with your My Oracle Support account. |
|
Don't have a My Oracle Support account? Click to get started! |
In this Document
Symptoms |
Cause |
Solution |
References |