robot framework连接Oracle错误:ORA-12504: TNS:listener was not given the SERVICE_NAME in CONNECT_DATA

在使用robot framework的关键字Connect to Database Using Custom params连接Oracle数据库:

Connect to Database Using Custom params         cx_Oracle      'username','password','host'   

报错 ORA-12504: TNS:listener was not given the SERVICE_NAME in CONNECT_DATA

解决方法:

在host后加上所连接数据库的库名(就是Oracle配置文件tnsnames.ora中的SERVICE_NAME)

如:

Connect to Database Using Custom params cx_Oracle 'username','password','host/orcl'   

 

posted @ 2018-03-16 09:08  傲娇的草履虫  阅读(7263)  评论(1编辑  收藏  举报