Windows安装mysql-python提示:error: Microsoft Visual C++ 9.0 is required,Get it from http://aka.ms/vcpython27。问题如何解决呢?
方法如下:
在http://www.lfd.uci.edu/~gohlke/pythonlibs/#mysql-python下载对应的包版本,如果是win7 64位2.7版本的python,就下载MySQL_python-1.2.5-cp27-none-win_amd64.whl
下载完之后保存该文件,然后在命令行执行pip install MySQL_python-1.2.5-cp27-none-win_amd64.whl
当然需要在cmd下跳转到下载MySQL_python-1.2.5-cp27-none-win_amd64.whl的目录下
然后就安装成功了MySQL-python
D:\Python>pip install MySQL_python-1.2.5-cp27-none-win32.whl
Processing d:\python\mysql_python-1.2.5-cp27-none-win32.whl
Installing collected packages: MySQL-python
Successfully installed MySQL-python-1.2.5