0

I have two database users on the same server like test_user, test_customer.

My requirement is to create a trigger in test_user that will execute on insertion in any table in both the user test_user, test_customer like cust_id in Test_customer as well as user_id in Test_user.

How I can I do that?

Noman Akhtar
  • 690
  • 1
  • 12
  • 17

1 Answers1

0

Try this. This is worked for me:

create trigger after_update_user

after update on db_test_user.user for each row
  update table db_test_customer.user set field = NEW.field where id = new.id;