6

I have installed 3.3.0 python installer in windows. Then I want to install MySQLdb. I search the installation file for python 3.3.0, I got "MySQL-python-1.2.4b4.win32-py2.7" and installed it. But it shows that 'python version 2.7 required, which is not found in your registry'. I also got the solution in stackoverflow about this problem but my problem was not solved. What I have tried is explained below :

1. First I have exported python from registry HKEY_LOCAL_MACHINE-> Software.
2. I have saved the file in desktop.
3. I open it with notepad++.
4. Then I replaced all the LOCAL_MACHINE with CURRENT_USER and save it.
5. Finally  I executed the saved file in desktop.

But nothing happened, my problem is not solved and as it is as it before was. Is there any solution for it ?

1
  • you have 64-bit Python, but a 32-bit installer of new modules... so error occurs.. Commented Jan 20, 2013 at 15:16

1 Answer 1

2

Python libraries that uses compiled C extensions must be compiled against the exact version of Python. The MySQLdb package you downloaded is for python 2.7 and wouldn't work on python 3.3.

As far as I can tell, the MySQLdb does not support Python 3 yet and there's no plan to port it to Python 3

All hope is not lose, however. There are other MySQL wrappers, see MySQL-db lib for Python 3.x?

Sign up to request clarification or add additional context in comments.

2 Comments

I have followed the instructions that you have suggested me but I could not install PyMySQL3-0.4. I am using windows 8 Pro 32-bit, whne I double click on setup.py it displays a command window and happens nothing. Can help me onwards ?
@BishnuBhattarai: run in a cmd window instead of double clicking it. distutil's setup.py usually would only display help text when run without any arguments. You'll need to pass the right arguments to install, usually "python setup.py install" or "C:\Path\To\Python\python.exe setup.py install". Better though, is to use easy_install or pip to install packages from PyPI.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.