Home » SQL & PL/SQL » SQL & PL/SQL » DBMS_OUTPUT Error (Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production)
DBMS_OUTPUT Error [message #576554] Wed, 06 February 2013 04:16 Go to next message
sgollapudi
Messages: 9
Registered: January 2013
Location: HYDERABAD
Junior Member
Hi All,

When I execute below in pl/sql developer I am getting error like
'pl/sql numeric or value error' where as in sql*plus if i execute it is working fine.

DECLARE
col CLOB := '(';
BEGIN
FOR i IN 1..1000 LOOP
col := col
||'col'
||i
||' char,';
END LOOP;

dbms_output.Put_line(col);
END;
Re: DBMS_OUTPUT Error [message #576556 is a reply to message #576554] Wed, 06 February 2013 04:18 Go to previous messageGo to next message
Littlefoot
Messages: 19314
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Oracle errors aren't "like" - they have their code (ORA-xxxxx) and name. It usually helps when you specify it exactly, not "like".

Because - your code works just fine for me.
Re: DBMS_OUTPUT Error [message #576565 is a reply to message #576554] Wed, 06 February 2013 04:40 Go to previous messageGo to next message
Michel Cadot
Messages: 58573
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
From your previous topic:

Michel Cadot wrote on Mon, 21 January 2013 11:26
From your previous topic:

Michel Cadot wrote on Fri, 18 January 2013 10:41
From your previous topics:

cookiemonster wrote on Tue, 15 January 2013 14:51
Please read and follow How to use [code] tags and make your code easier to read?
...


sgollapudi wrote on Thu, 17 January 2013 16:27
...
*BlackSwan added {code} tags. Please do so yourself in the future.

...

...
Regards
Michel

Re: DBMS_OUTPUT Error [message #576569 is a reply to message #576556] Wed, 06 February 2013 04:47 Go to previous messageGo to next message
sgollapudi
Messages: 9
Registered: January 2013
Location: HYDERABAD
Junior Member
Hi LittleFoot, agree with you when I execute the code i am getting below error in
pl/sql developer(Version 9.0.0.1601) but it working fine in sql*plus.
If it is working fine for you in pl/sql developer.
Could you please let me know the version of it.

ORA-06502: PL/SQL: numeric or value error; character string buffer too small
ORA-06512: at "SYS.DBMS_OUTPUT", LINE 151
ORA-06512: at line 2

DECLARE
col CLOB := '(';
BEGIN
FOR i IN 1..1000 LOOP
col := col
||'col'
||i
||' char,';
END LOOP;

dbms_output.Put_line(col);
END;

Thanks in advance

SG
Re: DBMS_OUTPUT Error [message #576570 is a reply to message #576569] Wed, 06 February 2013 04:53 Go to previous messageGo to next message
Littlefoot
Messages: 19314
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Is your DBMS_OUTPUT buffer too small? Can you make it larger? (I don't use PL/SQL Developer but TOAD so - sorry, don't know PL/SQL Developer's options at all).
Re: DBMS_OUTPUT Error [message #576574 is a reply to message #576570] Wed, 06 February 2013 05:50 Go to previous messageGo to next message
cookiemonster
Messages: 10846
Registered: September 2008
Location: Rainy Manchester
Senior Member
What's the buffer size (at the top of the output tab) set to?
Re: DBMS_OUTPUT Error [message #576578 is a reply to message #576569] Wed, 06 February 2013 05:56 Go to previous message
Michel Cadot
Messages: 58573
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
sgollapudi wrote on Wed, 06 February 2013 11:47
Hi LittleFoot, agree with you when I execute the code i am getting below error in
pl/sql developer(Version 9.0.0.1601) but it working fine in sql*plus.
If it is working fine for you in pl/sql developer.
Could you please let me know the version of it.

ORA-06502: PL/SQL: numeric or value error; character string buffer too small
ORA-06512: at "SYS.DBMS_OUTPUT", LINE 151
ORA-06512: at line 2

DECLARE
col CLOB := '(';
BEGIN
FOR i IN 1..1000 LOOP
col := col
||'col'
||i
||' char,';
END LOOP;

dbms_output.Put_line(col);
END;

Thanks in advance

SG


Michel Cadot wrote on Wed, 06 February 2013 11:40
From your previous topic:

Michel Cadot wrote on Mon, 21 January 2013 11:26
From your previous topic:

Michel Cadot wrote on Fri, 18 January 2013 10:41
From your previous topics:

cookiemonster wrote on Tue, 15 January 2013 14:51
Please read and follow How to use [code] tags and make your code easier to read?
...


sgollapudi wrote on Thu, 17 January 2013 16:27
...
*BlackSwan added {code} tags. Please do so yourself in the future.

...

...
Regards
Michel


[Updated on: Wed, 06 February 2013 05:57]

Report message to a moderator

Previous Topic: Converting BLOB data to long or varchar
Next Topic: Please provide function for going at start and end time for the day from sysdate
Goto Forum:
  


Current Time: Fri Jul 25 18:44:32 CDT 2014

Total time taken to generate the page: 0.14698 seconds