Debug Trigger?
DBAsupport.com Forums - Powered by vBulletin
Results 1 to 4 of 4

Thread: Debug Trigger?

Hybrid View

  1. #1
    Join Date
    Apr 2002
    Posts
    61

    Question

    Hi,
    I use dbms_output.put_line when I create and run a function or procedure to see what are the values for variables at several locations in the program.
    Is there anything like this to debug trigger?
    Thanks,
    Ramesh

  2. #2
    Join Date
    Dec 2000
    Location
    Ljubljana, Slovenia
    Posts
    4,439
    You can use autonomous transactions inside the trigger - store (and commit) the debugging information into database tables from within the trigger.
    Jurij Modic
    ASCII a stupid question, get a stupid ANSI
    24 hours in a day .... 24 beer in a case .... coincidence?

  3. #3
    Join Date
    Apr 2002
    Posts
    61
    Hi Jurij,
    Thanks for your feedback, but I can commit within the trigger. So, if the trigger fails, I will not have any info in the table.

    ERROR at line 1:
    ORA-04092: cannot COMMIT in a trigger
    ORA-06512: at "QIS.T_WARR_BASED_ON_CARTID", line 61
    ORA-04088: error during execution of trigger 'QIS.T_WARR_BASED_ON_CARTID'

    Ramesh

  4. #4
    Join Date
    Dec 2000
    Location
    Ljubljana, Slovenia
    Posts
    4,439
    I said autonomous transactions. Check/search Oracle documentation (tahiti.oracle.com) by the therm "autonomous transaction".
    Jurij Modic
    ASCII a stupid question, get a stupid ANSI
    24 hours in a day .... 24 beer in a case .... coincidence?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width