问题:利用Python连接Oracle时报错,完整过程如下
import cx_Oracle conn = cx_Oracle.connect(‘testma/[email protected]:1521/orcl‘) Traceback (most recent call last): File "", line 1, in cx_Oracle.DatabaseError: ORA-12541: TNS:no listener
解决:
打开Oralce机器的Net Configuration Assistant,重新进行TNS配置。ps:若没有则添加一个。
cx_Oracle.DatabaseError: ORA-12541: TNS:no listener
时间: 2024-11-01 21:59:57