Chr☆s Kwok 的技术笔记

.NET, C#, WPF, WCF, WF, .NetCore & LINQ ... I know how it works because I know why it works ...

博客园 首页 新随笔 订阅 管理

1、tnsnames.ora文件定义了别名ORCL243(F:\app\guoshaoyue\product\11.2.0\client_1\network\admin\tnsnames.ora):

# tnsnames.ora Network Configuration File: f:\app\guoshaoyue\product\11.2.0\client_1\NETWORK\ADMIN\tnsnames.ora
# Generated by Oracle configuration tools.

ORCL242 =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = TCP)(HOST = 172.18.99.242)(PORT = 1521))
    )
    (CONNECT_DATA =
      (SERVICE_NAME = ORCL)
    )
  )

ORCL243 =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = TCP)(HOST = 172.18.99.243)(PORT = 1521))
    )
    (CONNECT_DATA =
      (SERVICE_NAME = ORCLBAK)
    )
  )
 
2、运行SQLPlus.exe(F:\app\guoshaoyue\product\11.2.0\client_1\BIN\sqlplus.exe)使用别名ORCL243和用户登录:
输入用户名(注意需要带上别名RCL243,以@符号为别名前缀):
 
也可以用户名和密码一起输入(apps/jetsun@orcl243):
退出SQLPLUS可以使用命令exit或者quit。

posted on 2022-03-22 17:53  Chr☆s  阅读(412)  评论(0编辑  收藏  举报