Oracle Error PLS-00229: Attribute expression within SQL expression

Oracle Error Message

PLS-00229: Attribute expression within SQL expression

Reason for the Error

An attribute expression, such as SQL%NOTFOUND, was used in a SQL statement, but attribute expressions are allowed only in procedural statements.

Solution

To workaround this limitation, assign the value of the attribute expression to a variable, then use the variable in the SQL statement. For example, replace the statement INSERT INTO audits VALUES (c1%ROWCOUNT, …); with the following statements: row_count := c1%ROWCOUNT; INSERT INTO audits VALUES (row_count, …);

Share:

Leave A Reply

Your email address will not be published. Required fields are marked *

You May Also Like

Oracle Error Message ORA-24328: illegal attribute value Reason for the Error The attribute value passed in is illegal. Solution Consult...
Oracle Error Message ORA-01346: LogMiner processed redo beyond specified reset log scn Reason for the Error LogMiner has detected a...
Oracle Error Message ORA-13241: specified dimensionality does not match that of the data Reason for the Error An error occurred...