Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Passing table name in dynamic SQL
In article <879890531.25781_at_dejanews.com>, mikep_at_quebec.net wrote:
>I'm trying to pass a Table name in a dynamic SQL call through PL/SQL. But
>I keep getting the error message Invalid Table name.
>
>Here's the snippet:
>
<snippet-ed>
>And here's the error I receive:
>
>Tue Nov 18 16:43:02 1997
>OWS-05101: Agent : execution failed due to Oracle error 903
>ORA-00903: invalid table name
>ORA-06512: at "SYS.DBMS_SYS_SQL", line 239
>ORA-06512: at "SYS.DBMS_SQL", line 25
>ORA-06512: at "COMMON.PAG", line 20
>ORA-06512: at line 1
Mike,
Stored procedures execute using the _explicitly_ granted rights of the owner of the stored procedure; that is, rights granted through roles are not recognized. Check that users expecting to call COMMON.PAG have explicitly been granted SELECT rights on the table in question. Hope this helps.
G.
![]() |
![]() |