I have a procedure which does a lot of inserts. I am getting a constraint violation, but it is not telling me which insert is causing it. I tried the exception catch below but it is not giving me enough detail.
EXCEPTION WHEN OTHERS THEN
ROLLBACK;
DBMS_OUTPUT.PUT_LINE('Procedure failed with: ' || SQLCODE || ' ' || SQLERRM);
DBMS_OUTPUT.put_line('Error in '|| $$plsql_unit || ' at ' || $$plsql_line);