How exactly is the GRANT/REVOKE privileges affecting the database.
I have a solution ready for a problem where one of my components(an executable) is not identifying my oracle config packages. But is it possible for me to test by revoking with this,
revoke execute on package_name to user1;
And then again grant,
grant execute on package_name to user1;
In short, can this in anyway affect the privileges negatively. This is mainly because user1 is a generic user so that's why I am being cautious.
Thanks
But of course that revoking a privilege affects that user negatively ... it won't be able to use that package any more.
Things can be even more complicated if that user (
user1
) has granted privilege to other users (as it was granted privilegewith grant option
) because - once you revoke privileges fromuser1
, Oracle will automatically revoke privileges from all those users/roles (that's what we'd call a cascading effect).Therefore, be careful. I guess that your best option to test it is to have a separate - testing - database. There you can do anything you want, as it won't affect nobody in production.
Finally, it is
revoke privilege FROM user
, notTO
(referring to the 1st statement you posted).