Permalink
Browse files

Apply constraints' schema normalization fix (a5ad49a) to indexes.

  • Loading branch information...
1 parent f696134 commit a3d8d16ff1e1ea6f3c79c9a5d6a11ffeb695c142 @jmafc jmafc committed Nov 29, 2011
Showing with 3 additions and 1 deletion.
  1. +3 −1 pyrseas/dbobject/index.py
@@ -6,7 +6,8 @@
This defines two classes, Index and IndexDict, derived
from DbSchemaObject and DbObjectDict, respectively.
"""
-from pyrseas.dbobject import DbObjectDict, DbSchemaObject, quote_id
+from pyrseas.dbobject import DbObjectDict, DbSchemaObject
+from pyrseas.dbobject import quote_id, split_schema_obj
class Index(DbSchemaObject):
@@ -106,6 +107,7 @@ def _from_catalog(self):
for index in self.fetch():
index.unqualify()
sch, tbl, idx = index.key()
+ sch, tbl = split_schema_obj('%s.%s' % (sch, tbl))
if index.keycols == '0':
del index.keycols
self[(sch, tbl, idx)] = index

0 comments on commit a3d8d16

Please sign in to comment.