summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/databases/mysql.py
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2006-10-24 22:53:36 +0000
committerMike Bayer <mike_mp@zzzcomputing.com>2006-10-24 22:53:36 +0000
commit427ee509bb3e8eb4a3700eb668151aca465f121f (patch)
tree73a0128818170d4189d9592e9a6f634fde7063de /lib/sqlalchemy/databases/mysql.py
parent5c1d4dbdaee4d3459ed0dd445e1a4c4c7c3e381b (diff)
downloadsqlalchemy-427ee509bb3e8eb4a3700eb668151aca465f121f.tar.gz
- MySQL catches exception on "describe" and reports as NoSuchTableError
Diffstat (limited to 'lib/sqlalchemy/databases/mysql.py')
-rw-r--r--lib/sqlalchemy/databases/mysql.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/sqlalchemy/databases/mysql.py b/lib/sqlalchemy/databases/mysql.py
index 86b74c364..671fbaf41 100644
--- a/lib/sqlalchemy/databases/mysql.py
+++ b/lib/sqlalchemy/databases/mysql.py
@@ -314,7 +314,10 @@ class MySQLDialect(ansisql.ANSIDialect):
if not case_sensitive:
table.name = table.name.lower()
table.metadata.tables[table.name]= table
- c = connection.execute("describe " + table.name, {})
+ try:
+ c = connection.execute("describe " + table.name, {})
+ except:
+ raise exceptions.NoSuchTableError(table.name)
found_table = False
while True:
row = c.fetchone()