HomeOracleOracle Error PLS-00509: Implementation Restriction : Pass a returned record to a temporary identifier before selecting a field

Oracle Error PLS-00509: Implementation Restriction : Pass a returned record to a temporary identifier before selecting a field

Oracle Error Message

PLS-00509: Implementation Restriction : Pass a returned record to a temporary identifier before selecting a field

Reason for the Error

Illegal syntax was used to call a parameter-less function that returns a record or a PL/SQL table of records. When calling a function that takes parameters and returns a record, you use the following syntax to reference fields in the record: function_name(parameters).field_name However, you cannot use the syntax above to call a parameter-less function because PL/SQL does not allow empty parameter lists. That is, the following syntax is illegal: function_name().field_name — illegal; empty parameter list You cannot just drop the empty parameter list because the following syntax is also illegal: function_name.field_name — illegal; no parameter list.

Solution

Declare a local record or PL/SQL table of records to which you can assign the function result, then reference its fields directly.

Share:

Leave a Reply

You May Also Like

Oracle Error Message CLSGN-32767: Internal error. Reason for the Error An unexpected error occurred. Solution Examine the message(s) that accompany...
Oracle Error Message CLSGN-00211: OCR batch operation failed. string Reason for the Error Setting a set of Oracle Cluster Registry...
Oracle Error Message CLSGN-00210: failed to get value for OCR key “string”. string Reason for the Error It was not...