NoSuchModuleError: Can't load plugin: sqlalchemy.dialects:teradata

[亡魂溺海] 提交于 2019-12-11 08:35:07

问题


Hi I am attempting to use sqlalchemy-teradata to write a pandas dataframe into a Teradata table. Here is the code I am using:

from sqlalchemy import create_engine
import sqlalchemy_teradata

td_engine=create_engine('teradata://'+uid+':'+password+'@'+host+':22/')

That comes back with the error above. I have also tried this code as well as I've seen this elsewhere on stackoverflow:

engine=create_engine('teradata://'+ uid +':' + password + '@'+ host + '/' + '?authentication=LDAP')

I have installed all of the following packages: sqlalchemy, sqlalchemy-teradata, and teradatasqlalchemy.

Has anyone seen this error before? Any help would be much appreciated!


回答1:


I would first of all check if the packages are installed correctly:

$ python
>>> import teradata
>>> import sqlalchemy_teradata

Does this give any error messages?

Also, I believe you only need the sqlalchemy-teradata package, not teradatasqlalchemy.



来源:https://stackoverflow.com/questions/52960393/nosuchmoduleerror-cant-load-plugin-sqlalchemy-dialectsteradata

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!