Electronics & Programming

develissimo

Open Source electronics development and programming

  • You are not logged in.

#1 Dec. 1, 2010 12:34:56

d.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

MySQL error


I am starting out to learn django and I am using the book: Beginning Django
E-Commerce by Jim McGaw.
I was able to create the database using mysql console but when I ran the
command:
$ python manager.py dbshell

I got the following error:

ow...@dipo /c/python26/djangojobs/ecomstore
$ python manage.py dbshell
Traceback (most recent call last):
File "manage.py", line 11, in <module>
execute_manager(settings)
File "c:\Python26\lib\site-packages\django-1.2.1-py2.6.egg\django\core\managem
ent\__init__.py", line 438, in execute_manager
utility.execute()
File "c:\Python26\lib\site-packages\django-1.2.1-py2.6.egg\django\core\managem
ent\__init__.py", line 379, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "c:\Python26\lib\site-packages\django-1.2.1-py2.6.egg\django\core\managem
ent\__init__.py", line 257, in fetch_command
klass = load_command_class(app_name, subcommand)
File "c:\Python26\lib\site-packages\django-1.2.1-py2.6.egg\django\core\managem
ent\__init__.py", line 67, in load_command_class
module = import_module('%s.management.commands.%s' % (app_name, name))
File "c:\Python26\lib\site-packages\django-1.2.1-py2.6.egg\django\utils\import
lib.py", line 35, in import_module
__import__(name)
File "c:\Python26\lib\site-packages\django-1.2.1-py2.6.egg\django\core\managem
ent\commands\dbshell.py", line 4, in <module>
from django.db import connections, DEFAULT_DB_ALIAS
File "c:\Python26\lib\site-packages\django-1.2.1-py2.6.egg\django\db\__init__.
py", line 75, in <module>
connection = connections
File "c:\Python26\lib\site-packages\django-1.2.1-py2.6.egg\django\db\utils.py"
, line 91, in __getitem__
backend = load_backend(db)
File "c:\Python26\lib\site-packages\django-1.2.1-py2.6.egg\django\db\utils.py"
, line 32, in load_backend
return import_module('.base', backend_name)
File "c:\Python26\lib\site-packages\django-1.2.1-py2.6.egg\django\utils\import
lib.py", line 35, in import_module
__import__(name)
File "c:\Python26\lib\site-packages\django-1.2.1-py2.6.egg\django\db\backends\
mysql\base.py", line 14, in <module>
raise ImproperlyConfigured("Error loading MySQLdb module: %s" % e)
django.core.exceptions.ImproperlyConfigured: Error loading MySQLdb module: No mo
dule named MySQLdb

Please what am I doing wrong.
Let me add that I installed wamp so the mysql I am using in bundled with apache
and php. I hope that is not the problem.

I hope to get a feedback.

Thank you.
Sent from my BlackBerry wireless device from MTN

--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.

Offline

#2 Dec. 1, 2010 12:47:04

Tom E.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

MySQL error


On Wed, Dec 1, 2010 at 10:09 AM, <delegb...@dudupay.com> wrote:
> I am starting out to learn django and I am using the book: Beginning Django
> E-Commerce by Jim McGaw.
> I was able to create the database using mysql console but when I ran the
> command:
> $ python manager.py dbshell
>
> I got the following error:
>
> django.core.exceptions.ImproperlyConfigured: Error loading MySQLdb module: No
> mo
> dule named MySQLdb
>
> Please what am I doing wrong.
> Let me add that I installed wamp so the mysql I am using in bundled with
> apache and php. I hope that is not the problem.
>
> I hope to get a feedback.
>

You need to install the python mysql driver. I have no idea what
'wamp' is, but I'm guessing it is some sort of bundled
apache/php/mysql stack? You will need to install the python mysql
driver in addition to that.http://sourceforge.net/projects/mysql-python/> Thank you.
> Sent from my BlackBerry wireless device from MTN
>

You wrote all that on a blackberry? Fair play..

Cheers

Tom

--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.

Offline

#3 Dec. 1, 2010 15:24:36

d.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

MySQL error


Thanks Tom, which one should I download for my django project?
There are about 9 files.

Kindly revert.

Regards.
Sent from my BlackBerry wireless device from MTN

-----Original Message-----
From: Tom Evans <tevans...@googlemail.com>
Sender: django-users@googlegroups.com
Date: Wed, 1 Dec 2010 12:46:53
To: <django-users@googlegroups.com>
Reply-To: django-users@googlegroups.com
Subject: Re: MySQL error

On Wed, Dec 1, 2010 at 10:09 AM, <delegb...@dudupay.com> wrote:
> I am starting out to learn django and I am using the book: Beginning Django
> E-Commerce by Jim McGaw.
> I was able to create the database using mysql console but when I ran the
> command:
> $ python manager.py dbshell
>
> I got the following error:
>
> django.core.exceptions.ImproperlyConfigured: Error loading MySQLdb module: No
> mo
> dule named MySQLdb
>
> Please what am I doing wrong.
> Let me add that I installed wamp so the mysql I am using in bundled with
> apache and php. I hope that is not the problem.
>
> I hope to get a feedback.
>

You need to install the python mysql driver. I have no idea what
'wamp' is, but I'm guessing it is some sort of bundled
apache/php/mysql stack? You will need to install the python mysql
driver in addition to that.http://sourceforge.net/projects/mysql-python/> Thank you.
> Sent from my BlackBerry wireless device from MTN
>

You wrote all that on a blackberry? Fair play..

Cheers

Tom

--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.

--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.

Offline

#4 Dec. 1, 2010 15:28:55

Tom E.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

MySQL error


On Wed, Dec 1, 2010 at 3:24 PM, <delegb...@dudupay.com> wrote:
> Thanks Tom, which one should I download for my django project?
> There are about 9 files.
>
> Kindly revert.
>
> Regards.
> Sent from my BlackBerry wireless device from MTN
>

I don't know; haven't used windows for ~10 years.

Google for 'python mysql windows howto' returns this top link..http://stackoverflow.com/questions/645943/mysql-for-python-in-windowsCheers

Tom

--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.

Offline

Board footer

Moderator control

Enjoy the 12th of December
PoweredBy

The Forums are managed by develissimo stuff members, if you find any issues or misplaced content please help us to fix it. Thank you! Tell us via Contact Options
Leave a Message
Welcome to Develissimo Live Support