how to force dbms_output.put_line to write the buffer more frequently
I use dbms_output.put_line() statements in my pl/sql code to help me log and debug my scripts.
However I noticed that after upgrading to oracle 10g, the buffer is not written to screen untill the code block is fully complete.
This is a problem, becasue:
1- I cannot use it to monitor progress of let's say a long loop in my pl/sql
2- If I run into a error and my plsql or stored procedure terminates, I will get no messages on screen or spool file to help me find the problem
Is there a fix, or workaround, to force dbms_output to flush buffer more frequently, or even better flush buffer real-time?