Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Access schema objects from another schema's package using a role

Posted on 2008-10-28
2
Medium Priority
?
1,181 Views
Last Modified: 2012-06-27
I created a schema named myconfigs which has 3 tables, a role which has select, update, delete on the three tables named myconfig_user. I have another schema named workuser that has been granted myconfig user role. If I do select * from myconfig.table1 the select statement works. If I put the select statement in a package named workuser.package1.selecttable1 proc I get insufficient privileges.

If I grant select access on myconfigs.table1 to workuser I can create the package. Why doesn't the role give sufficient privileges to access the tables in workuser.package stored procedures?
0
Comment
Question by:mandarins_nyc
2 Comments
 
LVL 29

Accepted Solution

by:
MikeOM_DBA earned 500 total points
ID: 22824390

Packages/Procedures DO NOT recognize role privileges. Yuo have to GRANT those privileges directly to the Package/Procedure owner.
-- OR --
Create package in the schema that owns the tables and GRANT execute on that procedure to the other schema (account).
0
 

Author Comment

by:mandarins_nyc
ID: 22824434
Thanks - this seems exactly what the case is unfortunately I was unable to find it in any oracle documentation.
0

Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article started out as an Experts-Exchange question, which then grew into a quick tip to go along with an IOUG presentation for the Collaborate confernce and then later grew again into a full blown article with expanded functionality and legacy…
When it comes to protecting Oracle Database servers and systems, there are a ton of myths out there. Here are the most common.
Via a live example show how to connect to RMAN, make basic configuration settings changes and then take a backup of a demo database
This video explains at a high level about the four available data types in Oracle and how dates can be manipulated by the user to get data into and out of the database.

926 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question