oracle帐号永久生效,oracle之sqlplus设置永久生效

注解:sqlplus是oracle自带的客户端字符管理工具,使用方便快速.但是经常需要对该工具的一些环境进行设置,不错,我们可以在使用的时候临时设置,可是我总觉得这很麻烦!所以就谷歌了一下,知道如何对环境,如linesize、pagesize、serveroutput等进行长久设置。

[oracle@oracle ~]$ sqlplus / as sysdba

SQL*Plus: Release 10.2.0.1.0 - Production on Wed Oct 19 11:19:29

2011

Copyright (c) 1982, 2005, Oracle. All rights

reserved.

Connected to an idle instance.

SQL> startup open;

ORACLE instance started.

Total System Global Area 734003200 bytes

Fixed

Size 1221564 bytes

Variable

Size 197135428 bytes

Database

Buffers 532676608 bytes

Redo

Buffers 2969600 bytes

Database mounted.

Database opened.

SQL> set linesize 100;

SQL> set pagesize 200;

SQL> set serveroutput on;

SQL> set autotrace on statistics

SQL> exit

SP2-0620: Error while disconnecting

Disconnected from Oracle Database 10g Enterprise Edition Release

10.2.0.1.0 - Production

With the Partitioning, OLAP and Data Mining options

[oracle@oracle ~]$ sqlplus / as sysdba

SQL*Plus: Release 10.2.0.1.0 - Production on Wed Oct 19 11:29:00

2011

Copyright (c) 1982, 2005, Oracle. All rights

reserved.

Connected to:

Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 -

Production

With the Partitioning, OLAP and Data Mining options

SQL> SQL>

SQL>

SQL> show linesize;

linesize 80

SQL> show pagesize;

pagesize 14

SQL> show serveroutput;

serveroutput OFF

SQL> show autotrace;

autotrace

OFF 设置完了后,退出sqlplus的话,刚才的设置显然失效!!!!

[root@oracle ~]# vim

/myoracle/product/10.2.0/db_1/sqlplus/admin/glogin.sql 修改该文件,永久生效。注意:glogin.sql是在你的安装目录。。。。。省略。。。。

set linesize 100

set pagesize 100

set serveroutput on

set autotrace on statistics

[oracle@oracle ~]$ sqlplus / as sysdba

SQL*Plus: Release 10.2.0.1.0 - Production on Wed Oct 19 11:30:56

2011

Copyright (c) 1982, 2005, Oracle. All rights

reserved.

Connected to:

Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 -

Production

With the Partitioning, OLAP and Data Mining options

SQL> show linesize

linesize 100

SQL> show serveroutput;

serveroutput ON SIZE UNLIMITED FORMAT WORD_WRAPPED

SQL> show autotrace;

autotrace ON STATISTICS

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值