Python 3 and Sybase and other databases

允我心安 提交于 2019-12-07 14:20:38

问题


I am new to python. Sorry if this is a noob question. But I am still searching on how can I connect to databases using python 3. Most of what I can see on some sites, forums, are about python 2. Is there any good DBAPI or database driver for python 3 (especially sybase, oracle and sqlserver)?

Or did anyone succeed on porting sybase library using 2to3? I have no luck. :(


回答1:


To use Python (2.6,2.7 and 3.1 are supported) with Sybase ASE you need two things:

  • sybpydb extension module for Python
  • Sybase Open Client SDK

Sybase has documentation for programmers wishing to connect to Sybase ASE with Python.

If you are using Python with Sybase SQLAnywhere you need the sqlanydb module.

Here is the documentation for using Sybase SQLAnywhere with Python.



来源:https://stackoverflow.com/questions/21902145/python-3-and-sybase-and-other-databases

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