Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Oracle plsql catching exceptions

In a procedure I'm inserting values into different tables, whenever a unique/primary key violation occurs for a table, I want to handle the exception specifically for that table. How can I catch different duplicate value exceptions?

like image 622
Rnet Avatar asked Aug 07 '26 13:08

Rnet


1 Answers

Check some tutorials like this.

Your unique/primary key violation will be a DUP_VAL_ON_INDEX exception.

like image 173
Udo Held Avatar answered Aug 10 '26 07:08

Udo Held



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!