oracle数据库中的default,在Oracle中,你如何改变" 默认" 数据库? (In Oracle, how do you change the 'default' database?)...

The correct question is 'How do I change the default service'? Oracle DBMS offers two types of connection request: explicit and implicit. In an explicit request, you supply three operands like sqlplus username/password@service. In an implicit request, you ignore the third operand.

Implicit connection applies only when the client-host and server-host are the same. Consequently, the listener is on the same host.

The listener is the one that initially responds to connection request. In handling the implicit-connection request from the same host,

it checks whether the instance name has been set. It checks the value of shell-variable ORACLE_SID.

If set, then it can handle implicit-connection request. Otherwise, it cannot, and you must perform explicit-connection request, supplying the third operand.

The listener-config file name listener.ora associates instance with service.

To change the default service you connect to, change the default value of instance.

Therefore, change the default value of shell-variable ORACLE_SID. You do it in the OS user config file such as .profile or similar config files.

Hope this helps.

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值