I have a table that logs certain information about procedures that are called PROCEDURE_NAME, PARAMETERS_PASSED, START_TIME,END_TIME, ERROR_MESSAGE ... and others
I am creating a procedure which inserts into this table the information I want. However, I do not know how I am to pass the error message from the stored procedure that is called into my new procedure
Is there a way to save this error message
EX)
SP1 - STARTS
SP1 - ENDS & THERE IS AN ERROR
LOG_STORED_PROCEDURE(SP1_NAME,SP1_PARAMETERS,SP1_START_TIME,SP1_END_TIME,ERROR_MESSAGE)