Django 1.6.2 - Python 3.3 - MySQL 5.6.17 Windows 7/8上的连接器问题

时间:2014-04-21 23:29:28

标签: python mysql django windows

我尝试过:

python manage.py syncdb

但是这个错误显示:

Traceback (most recent call last):
  File "C:\Python33\lib\site-packages\django\db\backends\mysql\base.py", line 14, in <module>
    import MySQLdb as Database
ImportError: No module named 'MySQLdb'

我从这里下载了Python 3.3.5:https://www.python.org/downloads/release/python-335/

此处的MySQL-Python连接器:http://dev.mysql.com/downloads/connector/python/

我正试图在Windows机器上设置它。尝试这个也不是运气:

pip install mysql-python

1 个答案:

答案 0 :(得分:0)

将settings.py中的引擎更改为 &#39; ENGINE&#39;:&#39; mysql.connector.django&#39;,