Forum Stats

  • 3,817,432 Users
  • 2,259,333 Discussions


How to handle exception of trigger created on base table

Hi Experts,

We have a requirement where we want to create trigger on MTL_SYSTEM_ITEMS_B. The trigger will check whenever reserve flag is updated on item, then trigger has to fire and capture the details in a custom table(The details we are capturing are: Old and New values of reserve flag, WHO Columns and few other).

Now, my doubt is how can we handle exception in a trigger. Is it allowed? Because, we are not sure what and when an error will occur right...?

As I said before, my trigger will have simple INSERT INTO CUSTOM TABLE statement.

If we handle exception(Which I need to know), how the application will show when we are updating reserve flag from application and how it will be displayed when we update the reserve flag by using UPDATE command from DB.

Thanks in Advance,