DBMS_OUTPUT not working (Doesn’t display anything)

From the Oracle SQL Developer, when you can’t see any output although you added DBMS_OUTPUT as following:

BEGIN
    DBMS_OUTPUT.PUT_LINE('This should be displayed');
END;

It doesn’t display anything as following:

You have two options to see the output.

  • Set Server output on the query window.
    Execute following script first.

    set serveroutput on size 30000;

    And the output will display as following:

  • Open DBMS_OUTPUT window.
    From the menu bar find DBMS_OUTPUT window and click.
    View -> DBMS_OUTPUT

    And it will display window as following and default buffer size is 20000.
    When you execute above the script it will display as following on the DBMS OUTPUT window.

Leave a Reply