tags:

views:

307

answers:

1
import MySQLdb

and

traceback:

Traceback (most recent call last):
  File "D:\zjm_code\sphinx_test\a.py", line 1, in <module>
    import MySQLdb
  File "D:\zjm_code\sphinx_test\MySQLdb\__init__.py", line 19, in <module>
    import _mysql
ImportError: No module named _mysql
+2  A: 

You need to install MySQLdb correctly. It consists of the python module and platform-dependent library (_mysql.dll in your case). Use the win32 installer from the project page instead of installing just by unpacking sources.

Eugene Morozov