I'm running Windows XP with WAMPSERVER 2.0 installed. Python2.6
MySQL is installed on my computer at this location: C:\wamp\bin\mysql
Here is how my settings.py is set up:
DATABASE_ENGINE = 'mysql'
DATABASE_NAME = 'pythonDB'
DATABASE_USER = 'py'
DATABASE_PASSWORD = '#py'
DATABASE_HOST = ''
DATABASE_PORT = '3306'
 I downloaded the adapter needed (MySQLdb, 
http://www.djangoproject.com/r/python-mysql/).
I used 7zip to place in C:\Python26\Lib\site-packages\MySQL-
python-1.2.2. When I cd to that and input 'setup.py install' , here
is
the output:
C:\Python26\Lib\site-packages\MySQL-python-1.2.2>setup.py install
running install
running bdist_egg
running egg_info
writing MySQL_python.egg-info\PKG-INFO
writing top-level names to MySQL_python.egg-info\top_level.txt
writing dependency_links to MySQL_python.egg-info
\dependency_links.txt
deleting MySQL_python.egg-info\native_libs.txt
reading manifest file 'MySQL_python.egg-info\SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'MySQL_python.egg-info\SOURCES.txt'
installing library code to build\bdist.win32\egg
running install_lib
running build_py
creating build
creating build\lib.win32-2.6
copying _mysql_exceptions.py -> build\lib.win32-2.6
creating build\lib.win32-2.6\MySQLdb
copying MySQLdb\__init__.py -> build\lib.win32-2.6\MySQLdb
copying MySQLdb\converters.py -> build\lib.win32-2.6\MySQLdb
copying MySQLdb\connections.py -> build\lib.win32-2.6\MySQLdb
copying MySQLdb\cursors.py -> build\lib.win32-2.6\MySQLdb
copying MySQLdb\release.py -> build\lib.win32-2.6\MySQLdb
copying MySQLdb\times.py -> build\lib.win32-2.6\MySQLdb
creating build\lib.win32-2.6\MySQLdb\constants
copying MySQLdb\constants\__init__.py -> build\lib.win32-2.6\MySQLdb
\constants
copying MySQLdb\constants\CR.py -> build\lib.win32-2.6\MySQLdb
\constants
copying MySQLdb\constants\FIELD_TYPE.py -> build
\lib.win32-2.6\MySQLdb
\constants
copying MySQLdb\constants\ER.py -> build\lib.win32-2.6\MySQLdb
\constants
copying MySQLdb\constants\FLAG.py -> build\lib.win32-2.6\MySQLdb
\constants
copying MySQLdb\constants\REFRESH.py -> build\lib.win32-2.6\MySQLdb
\constants
copying MySQLdb\constants\CLIENT.py -> build\lib.win32-2.6\MySQLdb
\constants
running build_ext
building '_mysql' extension
error: None
Ok notice the "building '_mysql' extension" part.
Now when I go to the Python Shell:
>>> import MySQLdb

Traceback (most recent call last):
   File "<stdin>", Line 1, in <module>
ImportError: No module named MySQLdb
If I put the MySQLdb folder in the site-packages dir:
>>> import MySQLdb

Traceback (most recent call last):
   File "<stdin>", Line 1, in <module>
   File "C:\Python26\Lib\site-packages\MySQLdb\__init__.py", line 19
in <module>
        import _mysql
ImportError: No module named _mysql
So my question is how do I correctly install the MySQLdb adapter? Or
more specifically, can my current setup be saved? (Go easy on me, I
just started with Django 2 days ago) Thanks bunches in advance ^^
  --Narshe

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to