Hi All,
I New in DB development. Please help me create trigger for moving data from one table to another. I have two tables one is containing "Transaction Status" from where I want to move records on transaction status change into another table having completed transactions. so the value in one table will get deleted and will get inserted into another table.
Please correct me in following trigger:
create trigger transaction_state after update on test_archive for each row begin insert into test_me(select * from test_archive where new.Transaction_status = 2); delete from test_archive where new.Transaction_status = 2; end;
Thanks to you all in advance.