Organizational Research By

Surprising Reserch Topic

rudimentary issue basic pl sql console output


rudimentary issue basic pl sql console output  using -'sql,oracle,plsql,oracle-sqldeveloper,dbms-output'

I am using SQL Developer and want to output the contents of a variable to the console using DBMS_OUTPUT.PUT_LINE().  I am running the following code that adds the numbers 1 through 5 inclusive but I'm not seeing any output.  

SET SERVEROUTPUT ON;
DECLARE
n_counter NUMBER := 5; -- Substitute this variable
n_sum     NUMBER := 0;
BEGIN
  WHILE n_counter != 0
  LOOP
    n_sum := n_sum + n_counter;
    n_counter := n_counter -1;
  END LOOP;
  DBMS_OUTPUT.PUT_LINE(n_sum);
END;


Additionally, do you Know of better resources for troubleshooting issues than the incredibly dense Oracle PL/SQL documentation? [similar to Java SE7 API?]
    
asked Sep 15, 2015 by ConniePrendi
0 votes
14 views



Related Hot Questions



Government Jobs Opening


...