开发者

can't import MySQLdb

Hi I ran the following scripts from macports and still can't run the import MySQLdb. Any idea what the problem could be?

开发者_JAVA百科
sudo port install py26-mysql 
sudo port install mysql5-server

>>> import MySQLdb
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: No module named MySQLdb
>>> 


Most likely you are not using Macports Python, but OSX native Python installation, or wrong version of Python from Macports.

Make sure you launch Python interpreter 2.6 from Macports.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜