Details
-
Task
-
Status: Closed (View Workflow)
-
Critical
-
Resolution: Duplicate
-
None
Description
PL/SQL packages in Oracle supports global package variables, that work a bit like session local variables, except they are types and initialized by packages obviously. Local package variables are supported, but these are only accessible from inside the package itself.
An example is this:
CREATE PACKAGE pkg1 IS |
global_var INTEGER := 1; |
END pkg1; |
/
|
CREATE PACKAGE BODY pkg1 IS |
local_var INTEGER := 2; |
END pkg1; |
/
|
After this declaration, local_var can be used by a procedure or function in the package, but not outside the package. The variable global_var though is accessible even from outside the package.
The requested feature is support for global package variables, i.e. variable declared in the package specification.
Attachments
Issue Links
- duplicates
-
MDEV-13139 CREATE PACKAGE: package-wide declarations
- Stalled