Oracle plsqldev1106 安装及TNS配置
下载好安装包,直接双击安装
点击 I Agree
默认是C盘的,我改了D盘,根据自己实际情况修改
这里用默认的for current user 也可以,我选了for all user
点Finish,等待安装完成即可
完成后,桌面就多了这个图标
准备好instantclient-basic-nt-11.2.0.4.0.zip包,解压之后是这样的:
新建D:\app\client_11\network\admin目录,从其他地方拷贝一个tnsnames.ora文件过来
tnsname.ora里面默认内容是这样的,没有从这里复制进去也行
# tnsnames.ora Network Configuration File.
# Generated by Oracle InstantClient tools.
# For more information, please visit: http://www.oracle.com/technetwork/database/features/instant-client/index-100365.html
# Sample:
#DatabaseName =
# (DESCRIPTION =
# (ADDRESS_LIST =
# (ADDRESS = (PROTOCOL = TCP)(HOST = 127.0.0.1)(PORT = 1521))
# )
# (CONNECT_DATA =
# (SERVER = DEDICATED)
# (SERVICE_NAME = ServiceName)
# (INSTANCE_NAME = InstanceName)
# )
# )
# Modify the following content to fit your own needs.
orcl155 =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 10.20.38.155)(PORT = 1521))
)
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = orcl)
)
)
cdb1@250 =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 10.20.26.250)(PORT = 1539))
)
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = cdb1)
)
)
upspy =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.45.157)(PORT = 1539))
)
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = ora11g)
)
)
FS_Test =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 10.20.32.146)(PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = ora11g)
)
)
打开plsql 客户端,首次打开,这里选Cancel
点击Tool, 选择第一个Preferences,把Oracle home , 和oci 库配置好,如下:
点击apply,再点OK即可
关闭软件,再次打开,这里就会出现我们tnsname.ora里面配置好的数据库
输入账号密码,登录,就可以操作数据库了