From: Malcolm Dew-Jones <>
Date: 24 Apr 2008 10:35:01 -0800
Message-ID: <4810c4c5$>

xylem ( wrote:
: Hi all,

: My procedure below is failing to provide the desired result and I've
: failed to track down what is the cause. The procedure is supposed to
: dynamically grant roll on objects to users. I've tested the cursor SQL
: and it's working fine. However, sql_stmt is failing. When I run the
: procedure I get the following error:

: Warning: Procedure created with compilation errors.

: SQL> sho err
: Errors for PROCEDURE G_R:

: -------- ----------------------------------------------------
: 35/3 PL/SQL: Statement ignored
: 35/50 PLS-00302: component 'VIEW_NAME' must be declared

You probably have access to 'VIEW_NAME' only thru a role.

The role will allow you to access the object interactively , but it will not allow you to compile code that needs to access the object.

Your username itself needs to be granted access to the object to compile code that accesses the object. Received on Thu Apr 24 2008 - 13:35:01 CDT

Original text of this message