安装MySQLdb python模块

时间:2010-12-07 20:08:45

标签: python mysql

我想在Windows 7上为Python安装MySQLdb模块,但是我收到错误

G:\python\python and mysql\MySQL-python-1.2.3b2\MySQL-python-1.2.3b2>setup.py
Traceback (most recent call last):
  File "G:\python\python and mysql\MySQL-python-1.2.3b2\MySQL-python-1.2.3b2\set
up.py", line 15, in <module>
    metadata, options = get_config()
  File "G:\python\python and mysql\MySQL-python-1.2.3b2\MySQL-python-1.2.3b2\set
up_windows.py", line 7, in get_config
    serverKey = _winreg.OpenKey(_winreg.HKEY_LOCAL_MACHINE, options['registry_ke
y'])
WindowsError: [Error 2]

G:\python\python and mysql\MySQL-python-1.2.3b2\MySQL-python-1.2.3b2>

1 个答案:

答案 0 :(得分:0)

This thread意味着问题是您需要在要使用客户端库的系统上安装mysql,即使您不在同一系统上使用该服务器。