Can't install mysql-python version 1.2.5 in Windows

http://stackoverflow.com/questions/37092125/cant-install-mysql-python-version-1-2-5-in-windows
 
No problem. We won't show you that ad again. Why didn't you like it?

  • Uninteresting
  • Misleading
  • Offensive
  • Repetitive
  • Other

Oops! I didn't mean to do this.

         up vote0down votefavorite

 

I have mysql-python v1.2.4 installed just fine on my machine (Windows 8). I am using Python 2.7. I always got this below error every time I try to upgrade to v1.2.5.

C:\Users\User\AppData\Local\Programs\Common\Microsoft\Visual C++ for Python\

9.0\VC\Bin\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -Dversion_info=(1,2,5,'fi nal',1) -D__version__=1.2.5 "-IC:\Program Files (x86)\MySQL\MySQL Connector C 6.  0.2\include" -Ic:\python27\include -Ic:\python27\PC /Tc_mysql.c /Fobuild\temp.wi n32-2.7\Release_mysql.obj /Zl      _mysql.c      _mysql.c(42) : fatal error C1083: Cannot open include file: 'config-win.h': No such file or directory      error: command 'C:\Users\User\AppData\Local\Programs\Common\Microsoft \Visual  C++ for Python\9.0\VC\Bin\cl.exe' failed with exit status 2

----------------------------------------   Rolling back uninstall of mysql-python Command "c:\python27\python.exe -u -c "import

setuptools, tokenize;file='c:\  \users\user\appdata\local\temp\pip-build-utz7of\MySQL-python\setup.py';ex  ec(compile(getattr(tokenize, 'open',  open)(file).read().replace('\r\n', '\n' ), file, 'exec'))"  install --record c:\users\user\appdata\local\temp\pip-osy  _cg-record\install-record.txt --single-version-externally-managed --compile" fai led with error code 1 in c:\users\user\appdata\local\temp\pip-build-utz7of\MySQL  -python\

I've tried (and none work):

  1. Installing VS2010
  2. Changing Python Path
  3. Using Wheel module (I got Failed building wheel for MySQL-python)
  4. Installing Python MySQL connector. For both Python and C.
  5. Installing mysqlclient
  6. Installing using Exe installer from https://pypi.python.org/pypi/mysql-python/1.2.5

Do I miss something? Thanks.

Magnus Lind Oxlund

54212        
        asked May 7 at 18:21    
Aminah Nuraini

1,8361026        
                                                                                                                    
I don't understand why do I get a down vote. It is similar to some questions, but I've tried their solution and none work. Please explain the down vote reason if you want to act that way                     – Aminah Nuraini                 May 9 at 4:28                                                                            
                                                                                                                    
What happened when you used the exe installer?                     – Burhan Khalid                 May 9 at 4:46                                                                            
                                                                                                                    
It got installed just fine, but then I still fail to install mysql-python                     – Aminah Nuraini                 May 9 at 4:49                                                                            
                                                                                                                    
How do you know it failed? Did you try to import it and get an error?                     – Burhan Khalid                 May 9 at 5:24                                                                            
                                                                                                                    
I keep getting the error I've pasted in the question. Can't find config-win.h, etc.                     – Aminah Nuraini                 May 9 at 5:54                                                                            
 |              show 1 more comment        

1 Answer                                 1

active         oldest         votes
         up vote0down voteaccepted

I solved it myself.

I use the wheel installer from http://www.lfd.uci.edu/~gohlke/pythonlibs/#mysql-python.

There are two wheel packages there. The amd64 one refuses to install on my platform (Windows) but the other one works just fine. I mean the file with this name:

MySQL_python-1.2.5-cp27-none-win32.whl

Then install it by running this below command in the same folder with the wheel package.

pip install MySQL_python-1.2.5-cp27-none-win32.whl

Can't install mysql-python version 1.2.5 in Windows的更多相关文章

  1. How to Access MySQL with Python Version 3.4

    http://askubuntu.com/questions/630728/how-to-access-mysql-with-python-version-3-4 How to Access MySQ ...

  2. pip install报错:RuntimeError: Python version >= 3.5 required

    由于pip官方的不作为,现如今python2(以及某些低版本python3)配套的pip,已经没法正常的安装pypi包了. 例如需要用到的一套PyCaffe的代码,是基于Python2的,于是用min ...

  3. How do you install mysql-connector-python (development version) through pip?

    12down votefavorite 8 http://stackoverflow.com/questions/31748278/how-do-you-install-mysql-connector ...

  4. How to install Mysql in the CentOS

    This article will walk through you the process of installing and updating latest MySQL 5.7.9 version ...

  5. 02_已解决 [salt.minion :1758][ERROR ][52886] Returner mysql.returner could not be loaded: 'mysql' __virtual__ returned False: Could not import mysql returner; mysql python client is not installed.

    总结:python2.7下的salt,要把 mysql-python也安装,并不是python3环境,看清,看清 Returners组件,master自动把值写入mysql数据库中,出现的问题 1.本 ...

  6. 在OSX狮子(Lion)上安装MYSQL(Install MySQL on Mac OSX)

    这篇文章简述了在Mac OSX狮子(Lion)上安装MySQL Community Server最新版本v10.6.7的过程. MySQL是最流行的开源数据库管理系统.首先,从MySQL的下载页面上下 ...

  7. 【亲测】Python:解决方案:Python Version 2.7 required, which was not found in the registry

    好久不更新随笔了,今天因为数据可视化作业,想抓取一些人人网好友关系数据,于是开始尝试python,用到numpy模块,安装的时候提示: 'Python Version 2.7 required, wh ...

  8. 96、python version 3.6 required,which was not fount in the registry(python3.6安装scrapy)

    在安装scrapy时遇到问题 环境:win10(64位), Python3.6(64位) 安装scrapy: 1.安装wheel(安装后,便支持通过wheel文件安装软件) pip3 install ...

  9. How to change from default to alternative Python version on Debian Linux

    https://linuxconfig.org/how-to-change-from-default-to-alternative-python-version-on-debian-linux You ...

随机推荐

  1. Oracle Redo 以及 Archived日志简述

    Oracle通过Redo Archived实现数据的归档 什么是Redo日志 Redo日志记录了数据的变更,用于在数据库出现故障后,进行数据恢复. 功能主要由三个组件实现:Redo Log Buffe ...

  2. Atitit 深入了解UUID含义是通用唯一识别码 (Universally Unique Identifier),

    Atitit 深入了解UUID含义是通用唯一识别码 (Universally Unique Identifier), UUID1 作用1 组成1 全球唯一标识符(GUID)2 UUID 编辑 UUID ...

  3. Atitit.软件中见算法 程序设计五大种类算法

    Atitit.软件中见算法 程序设计五大种类算法 1. 算法的定义1 2. 算法的复杂度1 2.1. Algo cate2 3. 分治法2 4. 动态规划法2 5. 贪心算法3 6. 回溯法3 7. ...

  4. paip. 提升性能---hibernate的缓存使用 总结

    paip. 提升性能---hibernate的缓存使用 总结 作者Attilax  艾龙,  EMAIL:1466519819@qq.com  来源:attilax的专栏 地址:http://blog ...

  5. 来吧!带你玩转 Excel VBA

    来吧!带你玩转 Excel VBA 从错失良机到艰辛的DOS征程,从坎坷购机自学路到转机起程,从爱好到事业,他从一个完全不懂电脑的人到VBA高级应用者,一切全是自学…… 我是罗刚君,来自四川的一个小县 ...

  6. Java-set集合

    package exception; import java.util.Map; import java.util.TreeMap; import java.util.HashMap; public ...

  7. jQuery贪吃蛇--jQuery学习

    我用JQuery有一段时间了,越来越体会到其强大之处,于是自己尝试写了一个贪吃蛇小游戏,拿来与网友分享一下. 1. 了解JQuery.Timers 除用到了jQuery1.5.1之外,我还用到了jQu ...

  8. SSIS Component的ValidateExternalMetadata属性

    ValidateExternalMetadata Property Indicates whether the component validates its column metadata agai ...

  9. KendoUI系列:MultiSelect

    1.基本使用 1>.创建Input <link href="@Url.Content("~/Content/kendo/2014.1.318/kendo.common. ...

  10. 深入理解PHP内核(八)变量及数据类型-预定义变量

    原文链接:http://www.orlion.ga/249/ PHP脚本在执行的时候用户全局变量(在用户空间显示定义的变量)会保存在一个HashTable数据类型的符号表中(symbol_table) ...