初学连接Oracle数据错误:Listener refused the connection with the following error:ORA-12505

我的错误(供参考):
初学连接Oracle数据错误:Listener refused the connection with the following error:ORA-12505
jdbc:oracle:thin:@主机名称:端口号:SID

该行的SID错误

以sys 用户登录Oracle数据库

查询当前数据库实例名(SID):
SELECT INSTANCE_NAME FROM V$INSTANCE;
初学连接Oracle数据错误:Listener refused the connection with the following error:ORA-12505
使用查询到的SID,进行连接。

希望少花点时间找到问题吧!

相关文章: