Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> DBMS_OUTPUT

DBMS_OUTPUT

From: David Moss <David.Moss_at_fdmgroup.com>
Date: Wed, 3 Jan 2007 10:35:29 -0000
Message-ID: <39132CDDC017F3459FFD0F26B3F8A09F1D9B7C@fdm-mail01.fdmgroup.local>

Hi,

Just a quick question, hope someone can illuminate me... I'm trying to debug a function using dbms_output but I can't gt anything I ask it to print displayed (not immediately anyway)... sample session:

SQL> set serveroutput on;
SQL> show serveroutput;
serveroutput ON size 2000 format WORD_WRAPPED SQL> create or replace function test return number is begin DBMS_OUTPUT.put_line('Hello, world!'); return 0; end;   2 /

Function created.

SQL> select test() from dual;

    TEST()


         0

SQL> Am i missing something really obvious or is this some sort of bug? I also realized that if then i do:

SQL> create or replace procedure test2 is begin DBMS_OUTPUT.put_line('Hello again!'); end;   2 /

Procedure created.

SQL> select test() from dual;

    TEST()


         0

SQL> call test2();
Hello, world!
Hello, world!
Hello again!

Call completed.

SQL> odd... anyone?

Thanks,

David.

This message is confidential and is intended for the addressee only; unless clearly stated that this disclaimer should not apply, this e-mail is not intended to create legally binding commitments on behalf of FDM Group Plc, nor do its contents reflect the corporate views or policies of FDM. Any unauthorised disclosure, use or dissemination, either whole or partial, is prohibited. If you are not the intended recipient of the message, please notify the sender immediately.



This e-mail has been scanned for all viruses by Star Internet. The service is powered by MessageLabs. For more information on a proactive anti-virus service working around the clock, around the globe, visit: http://www.star.net.uk
--
http://www.freelists.org/webpage/oracle-l
Received on Wed Jan 03 2007 - 04:35:29 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US