mirror of
https://github.com/django/django.git
synced 2025-10-31 09:41:08 +00:00
Fixed #18013 -- Use the new 'as' syntax for exceptions.
Thanks Clueless for the initial patch. Note that unittest has been purposely left out (external package only used by Python 2.6).
This commit is contained in:
@@ -16,7 +16,7 @@ class OracleIntrospection(DatabaseIntrospection):
|
||||
cursor.execute('SELECT "DIMINFO", "SRID" FROM "USER_SDO_GEOM_METADATA" WHERE "TABLE_NAME"=%s AND "COLUMN_NAME"=%s',
|
||||
(table_name.upper(), geo_col.upper()))
|
||||
row = cursor.fetchone()
|
||||
except Exception, msg:
|
||||
except Exception as msg:
|
||||
raise Exception('Could not find entry in USER_SDO_GEOM_METADATA corresponding to "%s"."%s"\n'
|
||||
'Error message: %s.' % (table_name, geo_col, msg))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user