Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: problem with stored procedure

Re: problem with stored procedure

From: Vladimir M. Zakharychev <bob_at_dpsp-yes.com>
Date: Fri, 24 Jan 2003 18:46:44 +0300
Message-ID: <b0rn5c$s58$1@babylon.agtel.net>


> So, we have fred connecting and executing a procedure owned by scott,
> which does a select from an ALL_ view where owner = 'MARY'. Is the
> ALL_* view that of scott, who owns the procedure, or fred, who is
> connected and executing the procedure? Who has to have SELECT
> privileges on MARY's objects?

Unless the procedure is created with AUTHID CURRENT_USER, it is executed with privileges of its owner minus privileges granted through roles. For your case, ALL_* view will be queried with SCOTT's privileges and thus SCOTT should be granted some privs to be able to see MARY's objects. FRED should only be granted EXECUTE on the proc by SCOTT. AUTHID CURRENT_USER is a different story. These are executed with privileges of the caller and roles are active for them.

-- 
Vladimir Zakharychev (bob@dpsp-yes.com)                http://www.dpsp-yes.com
Dynamic PSP(tm) - the first true RAD toolkit for Oracle-based internet applications.
All opinions are mine and do not necessarily go in line with those of my employer.
Received on Fri Jan 24 2003 - 09:46:44 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US