1、MySQLdb模块下载安装

下载地址:

http://sourceforge.net/projects/mysql-python/files/mysql-python/1.2.3/

安装:

  $ tar xfz MySQL-python-1.2.1.tar.gz
  $ cd MySQL-python-1.2.1
  $ # edit site.cfg if necessary
  $ python setup.py build
  $ sudo python setup.py install # or su first

  

官网:

MySQL-3.23 through 5.5 and Python-2.4 through 2.7 are currently supported. Python-3.0 will be supported in a future release. 

这个是不支持python3的

 

2、python3 要连接mysql可以使用PyMySQL

pip install PyMySQL

 

posted on 2015-11-04 17:29  充实自己  阅读(304)  评论(0编辑  收藏  举报