Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

ORA-01031 insufficient privileges error when selecting from a view

JSebastianJan 5 2012 — edited Mar 8 2013
OK I think this might be a dumb question but I can't figure it out:

User John has been granted SELECT privilege (directly, not through a database role) to schema FRED.table1;
User John can issue select * from FRED.table1; and it works just fine.

User John has then been granted SELECT privilege (directly, not via a database role) to schema
MARK.view1;

MARK.view1 only selects from FRED.table1. No other tables are in the view1.
Schema MARK can successfully query the views. SELECT * FROM VIEW1 returns results.
I also checked the MARK schema to ensure that it has been granted SELECT on FRED.table1 directly which it has.

Now, when logged into schema John, I try SELECT * FROM MARK.VIEW1; and I get ORA-01031 insufficient privileges error.

I'm not sure how to troubleshoot this. If John is granted SELECT ANY TABLE, it of course works but I don't want John to have that powerful priv.

To recap, John has SELECT on both MARK.VIEW1 and the table which VIEW1 selects from (FRED.TABLE1).
John can select from FRED.TABLE1 no problem but receives a privilege error even though John has SELECT on MARK.VIEW1.

Any thoughts?

Oh, Oracle EE 10.2.0.4
This post has been answered by Tubby on Jan 5 2012
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 5 2013
Added on Jan 5 2012
5 comments
6,011 views