linux怎样连接oracle数据库

2024-11-23 04:15:35
推荐回答(1个)
回答1:

Linux系统下可以用sqlplus命令连接oracle数据库,方法如下:
sqlplus命令语法:
#sqlplus usr/pwd@//host:port/sid
#usr:用户名
#pwd:密码
#host:数据库服务器IP
#port:端口
#sid:数据库标识符
sqlplus命令连接Oracle示例:
[oracle@mzl ~]$ sqlplus risenet/1@//192.168.130.99:1521/risenet
SQL*Plus: Release 10.2.0.1.0 - Production on Mon Feb 18 15:53:34 2008
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle9i Enterprise Edition Release 9.2.0.1.0 - Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.1.0 - Production
#测试数据库select查询语句
SQL> select instance_name,status from v$instance;
INSTANCE_NAME STATUS
---------------- ------------
risenet OPEN
SQL>