Do not do this with the web based shell. There is a problem with mantaining the db state in the shell. We are looking it into it.
On Sep 2, 4:51 am, b vivek <[email protected]> wrote: > Ok, I am unable to use the shell for checking out mysql db. I have the > mysqldb driver installed and it works properly when I edit the controller > and the model and can see the tables being created in mysql .. however when > i use the shell, it does not work.. here are the commands I gave at the > shell > > 1.db=DAL('mysql://root:mypasswo...@localhost/web2') > > 2. print db._uri > mysql://root:mypasswo...@localhost/web2 > > 3.db.define_table('person', Field('name')) > Traceback (most recent call last): > File "<input>", line 1, in <module> > File "/home/vivek/web2py/gluon/sql.py", line 1359, in define_table > t._create(migrate=migrate, fake_migrate=fake_migrate) > File "/home/vivek/web2py/gluon/sql.py", line 1800, in _create > self._db._execute(query) > File "/home/vivek/web2py/gluon/sql.py", line 980, in <lambda> > self._execute = lambda *a, **b: self._cursor.execute(*a, **b) > File "build/bdist.linux-i686/egg/MySQLdb/cursors.py", line 155, in execute > charset = db.character_set_name() > InterfaceError: (0, '') > > Can somebody help me with this... !

