 |
|
Oracle dbms_output.put_line
Oracle Tips by Burleson Consulting |
Oracle dbms_output.put_line
The Oracle
dbms_output.put_line procedure allows you to write
data to flat file or to direct your PL/SQL output to a
screen.
Here is a code example using
dbms_output.put_line:

dbms_output.put_line('Fixed IO/SEC:'||to_char(fixed_io_per_sec,'9,999,999.99'));
dbms_output.put_line('Temp IO/SEC :'||to_char(temp_io_per_sec,
'9,999,999.99')); dbms_output.put_line('Total IO/SEC:'||to_char(tot_io_Per_Sec,
'9,999,999.99'));
dbms_output.put_line('FS1
Blocks = '||v_fs1_blocks); dbms_output.put_line('FS2
Blocks = '||v_fs2_blocks); dbms_output.put_line('FS3
Blocks = '||v_fs3_blocks); dbms_output.put_line('FS4
Blocks = '||v_fs4_blocks); dbms_output.put_line('Full
Blocks = '||v_full_blocks); end;
PL/SQL functions like the
dbms_output.put_line procedure will also trims off white
space.
The leading and training spaces will be
removed when placed in the buffer.
Here is an example of
dbms_output.put_line used to remove spaces:
dbms_output.put_line (‘ This has
spaces. ’);
The above example Oracle
dbms_output.put_line would remove the spaces before and
after the phrase "This has spaces".
For more information on dbms_output, see here.
|