ITPub博客

首页 > 数据库 > Oracle > 解决 plsql dev中ORA-20000 ORU-10027 buffer overflow, limit of 2000 bytes 问题

解决 plsql dev中ORA-20000 ORU-10027 buffer overflow, limit of 2000 bytes 问题

原创 Oracle 作者:cnhtm 时间:2010-03-12 16:14:35 0 删除 编辑

在plsql dev中使用dbms_output.put_line的时候报如下错误

ORA-20000: ORU-10027: buffer overflow, limit of 2000 bytes
ORA-06512: at "SYS.DBMS_OUTPUT", line 32
ORA-06512: at "SYS.DBMS_OUTPUT", line 97
ORA-06512: at "SYS.DBMS_OUTPUT", line 112
ORA-06512: at line 5

详细日志如下:

[@more@]
SQL>
SQL> set serveroutput on;
SQL> begin
2 for c in (select * from dba_objects)
3 loop
4 dbms_output.put_line(c.object_name);
5 end loop;
6 end;
7 /

ICOL$
I_USER1

... ...

I_SNAP_REFTIME1
MLOG_REFCOL$

begin
for c in (select * from dba_objects)
loop
dbms_output.put_line(c.object_name);
end loop;
end;

ORA-20000: ORU-10027: buffer overflow, limit of 2000 bytes
ORA-06512: at "SYS.DBMS_OUTPUT", line 32
ORA-06512: at "SYS.DBMS_OUTPUT", line 97
ORA-06512: at "SYS.DBMS_OUTPUT", line 112
ORA-06512: at line 5

SQL>

解决方法如下:

SQL> exec dbms_output.enable(9999999999);

PL/SQL procedure successfully completed

SQL>
SQL> begin
2 for c in (select * from dba_objects)
3 loop
4 dbms_output.put_line(c.object_name);
5 end loop;
6 end;
7 /

ICOL$
I_USER1
CON$
UNDO$

... ...

WRH$_SYS_TIME_MODEL
WRH$_SYS_TIME_MODEL_PK
WRH$_SYS_TIME_MODEL_PK
WRH$_SERVICE_WAIT_CLASS
WRH$_SERVICE_WAIT_CLASS_PK
WRH$_SERVICE_WAIT_CLASS_PK
BIG_TABLE
P_TEST

PL/SQL procedure successfully completed

SQL>

--end--

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/22049049/viewspace-1031882/ ,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论

注册时间:2009-07-06

  • 博文量
    104
  • 访问量
    812107