3
D:\PythonPack\MySQL-python-1.2.3>python setup.py install
Traceback (most recent call last):
  File "setup.py", line 15, in <module>
    metadata, options = get_config()
  File "D:\PythonPack\MySQL-python-1.2.3\setup_windows.py", line 7, in get_confi
g
    serverKey = _winreg.OpenKey(_winreg.HKEY_LOCAL_MACHINE, options['registry_ke
y'])
WindowsError: [Error 2] The system cannot find the file specified

I am trying to install mysqldb for python in windows7 and run into that error message

Do you have an idea how I can make it work ? I already have pythonsetuptool installed

shiva
  • 2,674
  • 4
  • 23
  • 37
Joe Mo
  • 115
  • 1
  • 3
  • 8

2 Answers2

3

Actually there are many ways and i tried them for few hours and realize its time waste process bcoz MYSQLdb is vary from version to version i.e 2.6,2.7 and 3.2 but all those are confuse and time waste processes, Instead best way is to get precompiled executables from : http://www.lfd.uci.edu/~gohlke/pythonlibs . here choose version wise links like python 2.7 and 32bit so that you won't get any errors and now run the downloaded file, finally set path in environment variables. Now open python IDLE editor or from command prompt c:>python import MySQLdb

if u don't get any errors then it's working fine...enjoy with u r work

Manoj
  • 31
  • 3
0

Just install with the exe from here.

And maybe you can find more information about this in the previous asked questions like this.

Community
  • 1
  • 1
Lenciel
  • 553
  • 3
  • 13