Windows使用pip安装MySQL-python报错fatal error C1083: Cannot open include file: 'config-win.h'
2016-08-28 00:04
831 查看
最近用到Python爬数据,要写到MySQL里,结果安装MySQLdb库有问题
使用pip安装:
结果报错:
然后查找方法,先安装了Microsoft Visual C++ Compiler for Python 2.7,附上链接:地址
结果还是报错
然后安装MySQL Connector,附上链接:MySQL Connector C
注1:这里要注意完整的报错信息,里面提到了查找‘config-win.h’的路径
因为Python是32位的,所以安装32位MySQL Connector,安装位置默认为C:\Program Files (x86)\MySQL Contractor C 6.0.2
然后成功安装MySQLdb
注2:这里要安装的是Connector/C,第一次直接安装了Connector/Python,就傻眼了
使用pip安装:
pip install MySQL-python
结果报错:
fatal error C1083: Cannot open include file: 'config-win.h' fatal error C1083: Cannot open include file: 'config-win.h'
然后查找方法,先安装了Microsoft Visual C++ Compiler for Python 2.7,附上链接:地址
结果还是报错
然后安装MySQL Connector,附上链接:MySQL Connector C
注1:这里要注意完整的报错信息,里面提到了查找‘config-win.h’的路径
因为Python是32位的,所以安装32位MySQL Connector,安装位置默认为C:\Program Files (x86)\MySQL Contractor C 6.0.2
然后成功安装MySQLdb
注2:这里要安装的是Connector/C,第一次直接安装了Connector/Python,就傻眼了
相关文章推荐
- win7 64 安装mysql-python:_mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h': N
- mysql-python 安装错误 fatal error C1083: Cannot open include file: 'config-win.h': No such file or direc
- mysql-python 安装错误 fatal error C1083: Cannot open include file: 'config-win.h': No such file or direc
- 安装pymysql、mysql-python 安装错误 fatal error C1083: Cannot open include file: 'config-win.h':
- mysql-python 安装错误 fatal error C1083: Cannot open include file: 'config-win.h': No such file or direc
- mysql-python 安装错误 fatal error C1083: Cannot open include file: 'config-win.h': No such file or direc
- mysql-python 安装错误: Cannot open include file: 'config-win.h': No such file or directory
- win7 64 安装mysql-python:fatal error C1083: Cannot open include file: 'config-win.h': No such file or
- 安装MySQL-python报错:_mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h': No such file or directory或者 build\lib.win-amd64-2.7\_mysql.pyd : fatal error LNK1120: 56 unresolved externa
- python3.5连接MySQL出现Cannot open include file: 'config-win.h': No such file or directory 错误解决办法
- mysql-python 安装错误: Cannot open include file: 'config-win.h': No such file or directory
- win7 64 安装mysql-python:_mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h': No such file or directory
- win7 64 安装mysql-python:_mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h': No such file or directory
- (转)win7 64 安装mysql-python:_mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h': No such file or directory
- mysql-python 安装错误 fatal error C1083: Cannot open include file: 'config-win.h': No such file or directory
- mysql-python:_mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h' 非权威指南
- _mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h':问题的解决
- _mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h':问题的解决
- _mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h':问题的解决