PLS-00492: variable or constant initialization may not refer
to functions declared in the same package



PLS-00492: variable or constant initialization may not refer to functions declared in the same pack..

Answer / guest

Cause: If a package spec p declares a function f, that
function may not be used in any variable declarations in
that same package spec. This is because of a circular
instantiation problem: in order to fully instantiate the
package spec, the variable must be initialized. To
initialize the variable, the function body code in the
package body must be executed. That requires that the
package body be instantiated. However, the package body
cannot be instantiated until the package spec is fully
instantiated.

Action: Remove the reference to the function from the
variable initialization. A technique which often works is to
move the variable initialization from the variable
declaration (in the package spec) to the package body
initialization block.

Please add more information about this Error

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Oracle Errors Interview Questions

ORA-03203: concurrent update activity makes space analysis impossible

1 Answers  


ORA-14321: cannot add/drop values to DEFAULT partition

1 Answers  


ORA-26064: Invalid SCN specified - Wrap: string Base: string.

1 Answers  


ORA-23310: object group "string"."string" is not quiesced

1 Answers  


ORA-32025: %s.string is not a table or view object.

1 Answers  


DRG-11440: operation not supported for the string language

1 Answers  


LFI-01004: Unable to empty buffer.

1 Answers  


ORA-22285: non-existent directory or file for string operation

1 Answers  


NNL-00290: Cancelled cache flush

1 Answers  


ORA-06564: object string does not exist

1 Answers  


ORA-02716: osnpgetdatmsg: message from host had incorrect message type

1 Answers  


ORA-01086: savepoint 'string' never established

1 Answers  


Categories