Looks like I learned something too. :)

Sincerely,
Saketh

On Thu, Jul 23, 2009 at 1:32 PM, Sonal Breed <sonal.br...@gmail.com> wrote:

>
> Saketh,
> I got the problem, it was the quotes around username and localhost,
> The command for mysql should be
> GRANT ALL ON django_db.* TO sonal@'ocalhost IDENTIFIED BY
> 'sonal';
>
>
> http://www.webdevelopersnotes.com/tutorials/sql/mysql_primer_creating_a_database.php3
>
> Thanks,
> Sonal.
>
> On Jul 23, 10:03 am, Sonal Breed <sonal.br...@gmail.com> wrote:
> > Hello saketh,
> > The name of the db is mygodb, i just happened to give the example of
> > Django_db in mysql console.
> > I am still getting the error. Does anybody know the solution to this??
> >
> > Any help will be really appreciated,
> > Sonal.
> >
> > On Jul 23, 9:47 am, Sonal Breed <sonal.br...@gmail.com> wrote:
> >
> > > Yes , the name of the database is mygodb..
> >
> > > On Jul 23, 9:45 am, Saketh <saketh.bhamidip...@gmail.com> wrote:
> >
> > > > You seem to be accessing 'mygodb' from your django config, for which
> > > > so...@localhost might not have permissions. Is this the case?
> >
> > > > Sincerely,
> > > > Saketh
> >
> > > > On Thu, Jul 23, 2009 at 12:42 PM, Sonal Breed <sonal.br...@gmail.com>
> wrote:
> >
> > > > > Hi all,
> >
> > > > > I am migrating my project from sqlite3 to mysql.
> > > > > Installed mysql and mysqldb on  my machine and executed following:
> >
> > > > >  mysql -u root -p
> > > > > Enter password:
> > > > > Welcome to the MySQL monitor.  Commands end with ; or \g.
> > > > > Your MySQL connection id is 1
> > > > > Server version: 5.0.51a-3ubuntu5.1 (Ubuntu)
> >
> > > > > Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
> >
> > > > > mysql> CREATE DATABASE django_db;
> > > > > Query OK, 1 row affected (0.01 sec)
> >
> > > > > mysql> GRANT ALL ON django_db.* TO 'sonal'@'localhost' IDENTIFIED
> BY
> > > > > 'sonal';
> > > > > Query OK, 0 rows affected (0.03 sec)
> >
> > > > > mysql> quit
> > > > > Bye
> >
> > > > > In settings.py
> > > > > DATABASE_ENGINE = 'mysql'           # 'postgresql_psycopg2',
> > > > > 'postgresql', 'mysql', 'sqlite3' or 'ado_mssql'.
> > > > > DATABASE_NAME = 'mygodb'             # Or path to database file if
> > > > > using sqlite3.
> > > > > DATABASE_USER = 'sonal '             # Not used with sqlite3.
> > > > > DATABASE_PASSWORD = 'sonal'         # Not used with sqlite3.
> > > > > DATABASE_HOST = ''             # Set to empty string for localhost.
> > > > > Not used with sqlite3.
> > > > > DATABASE_PORT = ''             # Set to empty string for default.
> Not
> > > > > used with sqlite3.
> >
> > > > > user sonal is already created in mysql with password sonal.
> >
> > > > > And the error message is
> >
> > > > > /var/lib/python-support/python2.6/MySQLdb/__init__.py:34:
> > > > > DeprecationWarning: the sets module is deprecated
> > > > >  from sets import ImmutableSet
> > > > > ...
> > > > > ...
> > > > > _mysql_exceptions.OperationalError: (1045, "Access denied for user
> > > > > 'sonal '@'localhost' (using password: YES)")
> >
> > > > > Thanks in advance,
> > > > > Sonal
> >
> >
> >
>

--~--~---------~--~----~------------~-------~--~----~
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 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to