Questions tagged [dbms-output]
145 questions
134
votes
8 answers
DBMS_OUTPUT.PUT_LINE not printing
When executing the following code, it just says the procedure is completed and doesn't print the infomation i want it to (firstName, lastName) and then the other values from the select query in a table below.
CREATE OR REPLACE PROCEDURE…

dexter
- 1,347
- 2
- 9
- 7
54
votes
6 answers
Is there any way to flush output from PL/SQL in Oracle?
I have an SQL script that is called from within a shell script and takes a long time to run. It currently contains dbms_output.put_line statements at various points. The output from these print statements appear in the log files, but only once the…

baxter
- 933
- 1
- 7
- 10
49
votes
10 answers
How to redirect the output of DBMS_OUTPUT.PUT_LINE to a file?
I need to debug in pl/sql to figure times of procedures, I want to use:
SELECT systimestamp FROM dual INTO time_db;
DBMS_OUTPUT.PUT_LINE('time before procedure ' || time_db);
but I don't understand where the output goes to and how can I redirect it…
aye
26
votes
1 answer
Rudimentary issue: basic PL/SQL console 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…
user1260503
25
votes
7 answers
Use dbms_output.put_line in Datagrip for .sql files
I started to use Datagrip for my PL/SQL (school) projects that need the use of DBMS_OUTPUT.PUT_LINE. Before this I was using Oracle SQL developer and I was able to use DBMS_OUTPUT by adding the following:
SET serveroutput ON;
There is a related…

Cezar Cobuz
- 1,077
- 1
- 12
- 34
24
votes
3 answers
How to increase dbms_output buffer?
I tried to debug my dynamic query via dbms_output but seems like the query string is too long for dbms_output buffer.
I got :
ORA-06502: PL/SQL: numeric or value error: character string buffer too small
ORA-06512: at "SYS.DBMS_OUTPUT", line…

hsuk
- 6,770
- 13
- 50
- 80
13
votes
1 answer
dbms_output cannot print boolean?
I am learning cursors and I cannot print the boolean value in the
dbms_output.put_line();
The code is
DECLARE
CURSOR c_employees_3i is
SELECT * FROM employees_3i;
row_count BOOLEAN;
BEGIN
OPEN c_employees_3i;
row_count := c_employees_3i%isopen;…

Shree Naath
- 477
- 2
- 5
- 18
7
votes
3 answers
Monitoring long-running PL/SQL block
I have a fairly time intensive PL/SQL block that builds fingerprints from molecular structures. I would like to print output to SQL*Plus console to provide feedback on how many structures have been processed. I can do this with…

James
- 83
- 2
- 5
7
votes
6 answers
dbms_output.put_line
Does dbms_output.put_line decrease the performance in plsql code?

Orange
- 71
- 1
- 2
7
votes
1 answer
DBMS_OUTPUT.PUT_LINE not printing anything
When executing the following code, it just says the procedure is completed and doesn't print the infomation .
BEGIN
dbms_output.put_line('This is my first program');
END;
/
When I execute the above code the compiler says , PL/SQL procedure…

osimer pothe
- 2,827
- 14
- 54
- 92
6
votes
2 answers
dbms_output size buffer overflow
I tried to set the dbms_output size to unlimited inside a stored procedure.
But it gave me compilation errors. So I tried in the SQL*Plus prompt the below way. But still I get the buffer overflow error. How can I overcome this?
set serveroutput…

Arav
- 4,957
- 23
- 77
- 123
6
votes
3 answers
Returning ids of a table where all values of other table exist with this id using all() or exists()
I have three tables with following data
Table 3 :
Table1_id Table2_id
1 1
1 2
1 3
2 1
2 3
3 2
Table 2 :
Table2_id Name
1 A
2 …

rcb_sp
- 65
- 5
6
votes
2 answers
Oracle - ORA-06502: PL/SQL: numeric or value error (DBMS_OUTPUT)
I implemented a function that returns clob data-type, and I would like to print the result in DBMS Output. Unfortunately, I am getting ORA-06502: PL/SQL: numeric or value error and I think it is due to the size of DBMS_OUTPUT.
This is the…

Adrian
- 836
- 7
- 20
- 44
6
votes
1 answer
what is equivalent of MySQL of DBMS_OUTPUT
I try to write a MySQL strored procedure, and want to send some output to console, or stdout.
Oracle use DBMS_OUTPUT.PUTLINE to debugginf.
Is there an equivalent of DBMS_OUTPUT in MySQL stored procedures?

ckl
- 71
- 1
- 1
- 4
5
votes
6 answers
Oracle: any replacements for DBMS_OUTPUT package?
especially one that doesn't have the 256 max chars/line
and 1000000 max chars/buffer limitation.

Mark Harrison
- 297,451
- 125
- 333
- 465