User SCOTT has been granted CREATE ANY TRIGGER AND ALTER ANY TABLE by the DBA.
HR is an existing schema in the database.
SCOTT creates the following trigger:
CREATE OR REPLACE TRIGGER drop_trigger
BEFORE DROP ON hr.SCHEMA
BEGIN
RAISE_APPLICATION_ERROR (-20000, ‘Cannot drop object’);
END:
SCOTT does not grant the execute privilege on this trigger to any other users.
For which user(s) would this trigger fire by default when they drop an object in the hr schema?
A.
Only HR
B.
SCOTT and HR
C.
Only SCOTT
D.
SCOTT, HR, and SYS
A
A
a
A
A
Using schema Scott:
——————
SQL Error: ORA-01031: insufficient privileges
01031. 00000 – “insufficient privileges”
*Cause: An attempt was made to perform a database operation without
the necessary privileges.
*Action: Ask your database administrator or designated security
administrator to grant you the necessary privileges
Using schema sys:
——————-
Table HR.EMP_TEMP dropped.
Using schema HR:
——————
SQL Error: ORA-00604: error occurred at recursive SQL level 1
ORA-20000: Cannot DROP object
ORA-06512: at line 1
So correct answer is A