So, looking for a mysql-db-lib that is compatible with py3k/py3.0/py3000, any ideas? Google turned up nothing.
那么,寻找与py3k/py3.0/py3000兼容的mysql-db-lib有什么想法吗?谷歌一无所获。
9 个解决方案
#1
2
As for future plans of MySQLdb, you might want to ask the author (Andy Dustman).
His blog is here: http://mysql-python.blogspot.com/
至于MySQLdb的未来计划,您可能要问作者(Andy清洁工)。他的博客在这里:http://mysql-python.blogspot.com/
#2
32
It appears the MySQLdb is pretty much a dead project. However, PyMySQL is a dbapi compliant, pure-python implementation of a mysql client, and it has python 3 support.
似乎MySQLdb几乎是一个死项目。但是,PyMySQL是一个兼容dbapi的、纯python实现的mysql客户机,并且它支持python 3。
EDIT: There's also MySQL Connector/Python. Same idea.
编辑:还有MySQL连接器/Python。同样的想法。
#3
7
I was looking for it too, but also found nothing, so I ported MySQL-python-1.2.3 to py3k you can read it here http://sourceforge.net/p/mysql-python/discussion/70460/thread/61e3a3c9/
我也在寻找它,但是没有发现任何东西,所以我将MySQL-python-1.2.3移植到py3k上,您可以在这里阅读http://sourceforge.net/p/mysql-python/discussion/70460/thread/61e3a3c9/
#4
4
There are currently a few options for using Python 3 with mysql:
目前有几个选择使用Python 3与mysql:
https://pypi.python.org/pypi/mysql-connector-python
https://pypi.python.org/pypi/mysql-connector-python
- Officially supported by Oracle
- 官方支持的甲骨文
- Pure python
- 纯python
- A little slow
- 有点慢
- Not compatible with MySQLdb
- 不兼容MySQLdb
https://pypi.python.org/pypi/pymysql
https://pypi.python.org/pypi/pymysql
- Pure python
- 纯python
- Faster than mysql-connector
- 速度比mysql-connector
- Almost completely compatible with
MySQLdb
, after callingpymysql.install_as_MySQLdb()
- 在调用pymysql.install_as_MySQLdb()之后,几乎完全兼容MySQLdb
https://pypi.python.org/pypi/cymysql
https://pypi.python.org/pypi/cymysql
- fork of pymysql with optional C speedups
- 带有可选C加速的pymysql分支
https://pypi.python.org/pypi/mysqlclient
https://pypi.python.org/pypi/mysqlclient
- Django's recommended library.
- Django的推荐图书馆。
- Friendly fork of the original MySQLdb, hopes to merge back some day
- 友好的分叉原来的MySQLdb,希望有一天能合并回来
- The fastest implementation, as it is C based.
- 最快的实现,因为它是基于C的。
- The most compatible with MySQLdb, as it is a fork
- 它是与MySQLdb最兼容的,因为它是一个fork
- Debian and Ubuntu use it to provide both
python-mysqldb
andpython3-mysqldb
packages. - Debian和Ubuntu使用它来提供python-mysqldb和python3-mysqldb包。
benchmarks here: https://github.com/methane/mysql-driver-benchmarks
基准:https://github.com/methane/mysql-driver-benchmarks
#5
2
Here is a working repository for Python 3: https://github.com/davispuh/MySQL-for-Python-3
下面是Python 3的工作存储库:https://github.com/davispuh/mysql -for Python-3
#6
1
not sure if you're still looking, but you could try this: http://sourceforge.net/projects/mypysql/
不知道您是否还在寻找,但是您可以试试这个:http://sourceforge.net/projects/mypysql/
#7
1
You can download the mysql-connector-python module compatible with Python3:
您可以下载与Python3兼容的mysql-connector-python模块:
http://rpm.pbone.net/index.php3/stat/4/idpl/15667200/dir/rawhide/com/mysql -连接器python3 0.3.2 fc16.noarch.rpm.html——2.
Get the "source RPM", unzip it and use it (e.g. put it in your PYTHONPATH, and look at the examples).
获取“源RPM”,解压缩并使用它(例如,将它放在PYTHONPATH中,并查看示例)。
#8
0
You're probably better off using Python 2.x at the moment. It's going to be a while before all Python packages are ported to 3.x, and I expect writing a library or application with 3.x at the moment would be quite frustrating.
您最好使用Python 2。x。将所有的Python包移植到3还需要一段时间。x,我希望用3编写一个库或应用程序。现在的x会很让人沮丧。
#9
0
There is an official Python 2/3 library, downloadable from MySQL website. Oracle released version 1.0.7 to public on 29 September 2012.
有一个官方的Python 2/3库,可从MySQL网站下载。Oracle在2012年9月29日向公众发布了1.0.7版本。
It's pure Python and works with MySQL 4.1+
它是纯Python,使用的是MySQL 4.1+。
See more details here: http://dev.mysql.com/doc/connector-python/en/connector-python.html
查看更多细节:http://devmy.sql.com/doc/connector - python/en/connec-python.html
I'm currently using it with MySQL 5.5 and Python 3.2 with no problems thus far :)
我目前正在使用MySQL 5.5和Python 3.2,到目前为止没有问题:)
#1
2
As for future plans of MySQLdb, you might want to ask the author (Andy Dustman).
His blog is here: http://mysql-python.blogspot.com/
至于MySQLdb的未来计划,您可能要问作者(Andy清洁工)。他的博客在这里:http://mysql-python.blogspot.com/
#2
32
It appears the MySQLdb is pretty much a dead project. However, PyMySQL is a dbapi compliant, pure-python implementation of a mysql client, and it has python 3 support.
似乎MySQLdb几乎是一个死项目。但是,PyMySQL是一个兼容dbapi的、纯python实现的mysql客户机,并且它支持python 3。
EDIT: There's also MySQL Connector/Python. Same idea.
编辑:还有MySQL连接器/Python。同样的想法。
#3
7
I was looking for it too, but also found nothing, so I ported MySQL-python-1.2.3 to py3k you can read it here http://sourceforge.net/p/mysql-python/discussion/70460/thread/61e3a3c9/
我也在寻找它,但是没有发现任何东西,所以我将MySQL-python-1.2.3移植到py3k上,您可以在这里阅读http://sourceforge.net/p/mysql-python/discussion/70460/thread/61e3a3c9/
#4
4
There are currently a few options for using Python 3 with mysql:
目前有几个选择使用Python 3与mysql:
https://pypi.python.org/pypi/mysql-connector-python
https://pypi.python.org/pypi/mysql-connector-python
- Officially supported by Oracle
- 官方支持的甲骨文
- Pure python
- 纯python
- A little slow
- 有点慢
- Not compatible with MySQLdb
- 不兼容MySQLdb
https://pypi.python.org/pypi/pymysql
https://pypi.python.org/pypi/pymysql
- Pure python
- 纯python
- Faster than mysql-connector
- 速度比mysql-connector
- Almost completely compatible with
MySQLdb
, after callingpymysql.install_as_MySQLdb()
- 在调用pymysql.install_as_MySQLdb()之后,几乎完全兼容MySQLdb
https://pypi.python.org/pypi/cymysql
https://pypi.python.org/pypi/cymysql
- fork of pymysql with optional C speedups
- 带有可选C加速的pymysql分支
https://pypi.python.org/pypi/mysqlclient
https://pypi.python.org/pypi/mysqlclient
- Django's recommended library.
- Django的推荐图书馆。
- Friendly fork of the original MySQLdb, hopes to merge back some day
- 友好的分叉原来的MySQLdb,希望有一天能合并回来
- The fastest implementation, as it is C based.
- 最快的实现,因为它是基于C的。
- The most compatible with MySQLdb, as it is a fork
- 它是与MySQLdb最兼容的,因为它是一个fork
- Debian and Ubuntu use it to provide both
python-mysqldb
andpython3-mysqldb
packages. - Debian和Ubuntu使用它来提供python-mysqldb和python3-mysqldb包。
benchmarks here: https://github.com/methane/mysql-driver-benchmarks
基准:https://github.com/methane/mysql-driver-benchmarks
#5
2
Here is a working repository for Python 3: https://github.com/davispuh/MySQL-for-Python-3
下面是Python 3的工作存储库:https://github.com/davispuh/mysql -for Python-3
#6
1
not sure if you're still looking, but you could try this: http://sourceforge.net/projects/mypysql/
不知道您是否还在寻找,但是您可以试试这个:http://sourceforge.net/projects/mypysql/
#7
1
You can download the mysql-connector-python module compatible with Python3:
您可以下载与Python3兼容的mysql-connector-python模块:
http://rpm.pbone.net/index.php3/stat/4/idpl/15667200/dir/rawhide/com/mysql -连接器python3 0.3.2 fc16.noarch.rpm.html——2.
Get the "source RPM", unzip it and use it (e.g. put it in your PYTHONPATH, and look at the examples).
获取“源RPM”,解压缩并使用它(例如,将它放在PYTHONPATH中,并查看示例)。
#8
0
You're probably better off using Python 2.x at the moment. It's going to be a while before all Python packages are ported to 3.x, and I expect writing a library or application with 3.x at the moment would be quite frustrating.
您最好使用Python 2。x。将所有的Python包移植到3还需要一段时间。x,我希望用3编写一个库或应用程序。现在的x会很让人沮丧。
#9
0
There is an official Python 2/3 library, downloadable from MySQL website. Oracle released version 1.0.7 to public on 29 September 2012.
有一个官方的Python 2/3库,可从MySQL网站下载。Oracle在2012年9月29日向公众发布了1.0.7版本。
It's pure Python and works with MySQL 4.1+
它是纯Python,使用的是MySQL 4.1+。
See more details here: http://dev.mysql.com/doc/connector-python/en/connector-python.html
查看更多细节:http://devmy.sql.com/doc/connector - python/en/connec-python.html
I'm currently using it with MySQL 5.5 and Python 3.2 with no problems thus far :)
我目前正在使用MySQL 5.5和Python 3.2,到目前为止没有问题:)