Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

dropping a very annoying trigger

I am stuck in a very unusal problem. There's one trigger I'd like to drop. Now when I drop it, it is dropped successfully.

drop trigger HRCS.hr_external_salary_in_trigger 

But when I run this command then I can see the trigger again:

select * from all_triggers where trigger_name like '%external%'

I can see this trigger in UI of PLSQL developer with red x on its head. Now when I try to delete it from left click menu then I get this error:

Error dropping HRCS.hr_external_salary_in_trigger
ORA-04080: trigger 'HR_EXTERNAL_SALARY_IN_TRIGGER' does not exist

Never saw this kind of behavior. Something which I deleted is still there but the program says it doesn't exist while showing it. o_O

How can I get rid of this undesirable annoyance

like image 484
Jaanna Avatar asked Jan 25 '26 08:01

Jaanna


2 Answers

Ok, I solved the problem

I used quotation marks as in:

drop trigger HRCS."hr_external_salary_in_trigger"

and it was dropped, finally.

Thanks all for replies :)

like image 96
Jaanna Avatar answered Jan 28 '26 07:01

Jaanna


Check the dependencies of that trigger using,

select * from dba_dependencies;

Find out if there are any dependencies or not. Check if you have created a synonym for that trigger.

like image 43
Dileep Avatar answered Jan 28 '26 08:01

Dileep



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!