Re: Execute privileges on PL/SQL function based upon role

From: Darius Carr <carrdj_at_logica.com>
Date: 1996/07/15
Message-ID: <4sdmkk$7mr_at_romeo.logica.co.uk>#1/1


>William D Carey wrote:
>>
>> The way the ORACLE manuals read, it seems legitimate to grant execute
>> on a function to a role and then grant the role to a user.
>> The user should then be able to execute the function.
>> Instead I get a PLS-00201 identifier 'FUNCTION_NAME' must be declared.
>> Granting execute on the function to the user directly worked as well
>> as granting execute on the function to PUBLIC.
 

>This is legitimate. Sounds like you aren't doing anything wrong. Set
>echo on and spool your output so we can review the syntax.

You do get this problem if calling the function in-line from a piece of SQL.

e.g.

select my_function()
from dual

Give the error unless access is granted directly to the user.

declare

   x number;
begin

   x:= my_function();
end;
/

Work with grants via a role

Hope this helps Received on Mon Jul 15 1996 - 00:00:00 CEST

Original text of this message