I have the following delete trigger
CREATE OR REPLACE TRIGGER db_admin_delete
BEFORE DELETE ON ADMININFO
FOR EACH ROW
execute immediate 'drop user ' || ld.username || ' cascade';
I have similar triggers for add and update, they work fine. But the above delete trigger gives the following exception:
ERROR at line 1:
ORA-01403: no data found
Can anyone please help me out here
I think you need to grant the DROP USER privilege to the trigger owner, even if the user has a powerful role like DBA.
I ran into something like this with a stored proc and execute immediate.
I have granted the trigger owner drop user privilege.
Click Here to Expand Forum to Full Width