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

From: Tan La <TLa_at_mtl.marconi.ca>
Date: 1996/07/09
Message-ID: <4ruh4v$ckj_at_gateway.marconi.ca>#1/1


In article <4rtu82$clk_at_portal.gmu.edu>, wcarey1_at_mason2.gmu.edu says...
>
>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.
>
>I tried this on Oracle v 7.1.4 on AIX 3 and the function is on a local
>database, not a remote one.
>
>I would appreciate any feedback on my problem.
>
>Will Carey
>
>

Because the function is not belong to the user; therefore, the function name must be fully qualify as OWNER.FUNCTION_NAME. Alternately, you can create a synonym or public synonym for the function. Then grant execute on function to a role and then grant the role to a user.

p.s. do not grant execute on the function to PUBLIC, because you already

     granted to role.

Tan. Received on Tue Jul 09 1996 - 00:00:00 CEST

Original text of this message