[20180109]sqlplus refcursor.txt

简介: [20180109]sqlplus refcursor.txt --//别人问的问题,如何在sqlplus使用refcursor定义的变量,我查询一下,做一个记录: SCOTT@book> @ &r/ver1 PORT_STRING         VERSI...

[20180109]sqlplus refcursor.txt

--//别人问的问题,如何在sqlplus使用refcursor定义的变量,我查询一下,做一个记录:

SCOTT@book> @ &r/ver1
PORT_STRING         VERSION    BANNER
------------------- ---------- ----------------------------------------------------------------------------
x86_64/Linux 2.4.xx 11.2.0.4.0 Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production

SCOTT@book> var x refcursor;
SCOTT@book> exec open :x for select * from dept;

PL/SQL procedure successfully completed.

SCOTT@book> print :x
    DEPTNO DNAME          LOC
---------- -------------- -------------
        10 ACCOUNTING     NEW YORK
        20 RESEARCH       DALLAS
        30 SALES          CHICAGO
        40 OPERATIONS     BOSTON

--//以前经常使用这样方式测试undo的ora-01555错误。

$ oerr ora 1555
01555, 00000, "snapshot too old: rollback segment number %s with name \"%s\" too small"
// *Cause: rollback records needed by a reader for consistent read are
//         overwritten by other writers
// *Action: If in Automatic Undo Management mode, increase undo_retention
//          setting. Otherwise, use larger rollback segments

目录
相关文章
|
关系型数据库 Oracle Linux
[20180321]ORA-08180.txt
[20180321]ORA-08180.txt $ oerr ora 08180 08180, 00000, "no snapshot found based on specified time" // *Cause: Could not match the time to an SCN from the mapping table.
1271 0
|
Oracle 关系型数据库 数据库管理
[20180211]关于oracle执行文件权限问题.txt
[20180211]关于oracle执行文件权限问题.txt --//如果oracle用户一般建立2个用户组.一般oinstall,dba组.缺省指定组oinstall --//如果数据库在运行时修改oracle执行文件权限,会到处一些进程出现问题.
1077 0
|
Oracle 关系型数据库 数据库
[20171208]ORA-16014(10G).txt
[20171208]ORA-16014(10G).txt --//别人配置dg遇到的问题,当时没有记录.在自己的环境做一个演示.这个问题相对隐藏很深.主要是自己不注意这些细节.
1183 0
|
Oracle 关系型数据库 Linux
|
SQL Oracle 关系型数据库
|
SQL 网络协议 Oracle
[20170419]ora-28547.txt
[20170419]ora-28547.txt --//测试环境,莫名奇妙使用toad登陆出现如下错误(使用ezconnect方式)。 ORA-28547: connection to server failed, probable Oracle Net adm...
1385 0
[20161021]关于sqlplus sqlprompt设置.txt
[20161021]关于sqlplus sqlprompt设置.txt --别人的服务器没有设置sqlprompt,随手设置一下,发现一些问题。 --从网上抄了下来: SYS@test> set sqlprompt "_user@_connect_identifier>" SYS@_connect_identifier> --居然变成这样。
1202 0
|
关系型数据库 Linux Oracle
[20160113]sqlplus使用问题.txt
[20160113]sqlplus使用问题.txt --在linux中使用sqlplus我自己经常遇到奇怪的问题,打入的命令无法执行,自己老是不知道什么回事,今天发现其中一个原因.
808 0
|
Oracle 关系型数据库 数据库
[20150529]ORA-16664.txt
[20150529]ORA-16664.txt --今天在例行检查中.执行 dgmgrl 出现ora-16664错误. --检查drcdbcn1.log文件,发现如下错误.
982 0
|
SQL Oracle 关系型数据库
[20141216]sqlplus的set appinfo.txt
[20141216]sqlplus的set appinfo.txt --今天学习了sqlplus的set appinfo命令,可以设置module参数。做一个简单记录。
645 0

热门文章

最新文章