Subject Handling exceptions and creating custom messages
Author un_spoken
Hello,

I would like to ask is it possible to catch an exception message and rethrow it after some modifications with my custom exception?

for example, something like this:

WHEN ANY DO
BEGIN
EXCEPTION MY_EXCEPTION 'An unexpected error occured: ' || ANY.message;
END

Where ANY.message is the original message from catched exception.

I could not find answer on the web so I am asking here.

Thanks in advance.