I have just started using web2py, but have used MVC in other programming languages, the problem I have gaot is importing a db from MySQL. I use the script in the scripts folder for extracting from MySQL, which worked fine. When I added to web2py, most of the tables work fine, but one table keeps giving an flash error saying "Invalid query
1054, "Unknown column 'user.id' in 'where clause'".Traceback (most recent call last):
File "/home/gazza/Downloads/web2py/applications/school/controllers/appadmin.py", line 250, in select
nrows = db(query, ignore_common_filters=True).count()
File "/home/gazza/Downloads/web2py/gluon/dal.py", line 10325, in count
return db._adapter.count(self.query,distinct)
File "/home/gazza/Downloads/web2py/gluon/dal.py", line 1851, in count
self.execute(self._count(query, distinct))
File "/home/gazza/Downloads/web2py/gluon/dal.py", line 1916, in execute
return self.log_execute(*a, **b)
File "/home/gazza/Downloads/web2py/gluon/dal.py", line 1910, in log_execute
ret = self.cursor.execute(command, *a[1:], **b)
File "/usr/lib/python2.7/dist-packages/MySQLdb/cursors.py", line 174, in execute
self.errorhandler(self, exc, value)
File "/usr/lib/python2.7/dist-packages/MySQLdb/connections.py", line 36, in defaulterrorhandler
raise errorclass, errorvalue
OperationalError: (1054, "Unknown column 'user.id' in 'where clause'")