Home » RDBMS Server » Server Administration » grant problems
grant problems [message #197906] Fri, 13 October 2006 04:31 Go to next message
Messages: 49
Registered: June 2006
Location: Romania
I have the following situation: I have an application and at a moment i need to give some grants to a user,through the application...
The user logs on "TEST" schema, this schema has DBA role...the grant is : "GRANT SELECT ON mmm.NBANK TO ROLE_mmm_OBJ" . 'mmm' user exists and also the 'NBANK' table exists in mmm's schema, and i get the following error: ORA-00942: table or view does not exist

If I try that grant under SQL*Plus(also logged as TEST) it successfully works...Can anyone give me a hint to this problem, please???

[Updated on: Fri, 13 October 2006 06:52]

Report message to a moderator

Re: grant problems [message #197921 is a reply to message #197906] Fri, 13 October 2006 04:57 Go to previous message
Messages: 20847
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Are you sure that this statement works through PL/SQL? Did you, perhaps, mean to say "through SQL"?

DBA is a role; privileges given directly to the user will be fine, but those given through roles will not be seen. In other words, SQL statement will work in SQL*Plus, but not in PL/SQL.

What to do? Grant required privileges directly to the user, or - if possible - move all tables into one schema. One more option would be defining procedures you use with invoker rights.

However, if this is not the point here, hmmm ... http://www.orafaq.com/forum/fa/1600/0/
Previous Topic: Remove defunct/unused Oracle services in Windows XP
Next Topic: EXP ERROR -Urgent
Goto Forum:

Current Time: Fri Oct 28 11:40:02 CDT 2016

Total time taken to generate the page: 0.08321 seconds