I have an Informix database (testdb) where web2py creates the necessary table but returns the following error from the web UI. I have looked through the code, but haven't been able to locate the exact area of the problem. Would someone point me in the direction of where to specifically look for this.
Traceback (most recent call last): File "/opt/web2py_svn_rev1141/gluon/restricted.py", line 178, in restricted exec ccode in environment File "/opt/web2py_svn_rev1141/applications/testapp/models/db.py", line 57, in <module> auth.define_tables() # creates all needed tables File "/opt/web2py_svn_rev1141/gluon/tools.py", line 528, in define_tables self.__get_migrate(self.settings.table_user_name, migrate)) File "/opt/web2py_svn_rev1141/gluon/sql.py", line 1008, in define_table query = t._create(migrate=migrate) File "/opt/web2py_svn_rev1141/gluon/sql.py", line 1343, in _create self._db._execute(query) File "/opt/web2py_svn_rev1141/gluon/sql.py", line 902, in <lambda> self._execute = lambda a: self._cursor.execute(a[:-1]) ProgrammingError: SQLCODE -310 in EXECUTE: S0001: Base table or viewed table already exists Informix returns the -310 which means... -310 Table table-name already exists in database. This statement tries to create a table with the name that is shown, but one with that name already exists. Only one table with a given name can exist in a single database. (In an ANSI-compliant database, the name of the user that created a table name qualifies it, so one table of a given name per user can exist.) Check the spelling of the name; if it is as you intended, and you are sure it should not exist, check that you are using the right database. You can review the names of all tables in this database by querying systables as follows: SELECT tabname FROM systables WHERE tabid > 99 This statement will display only names of permanent tables, not temporary tables. Temporary tables do not appear in systables. If the name does not appear, end your database session and start a new one. Temporary tables will be dropped. Thank you, Christopher --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~----------~----~----~----~------~----~------~--~---