equal
deleted
inserted
replaced
90 repo = cnx.repo |
90 repo = cnx.repo |
91 dbhelper = repo.system_source.dbhelper |
91 dbhelper = repo.system_source.dbhelper |
92 |
92 |
93 # Computed Rtype |
93 # Computed Rtype |
94 tables = set(t.lower() for t in dbhelper.list_tables(cnx.cnxset.cu)) |
94 tables = set(t.lower() for t in dbhelper.list_tables(cnx.cnxset.cu)) |
|
95 # on postgres, ensure the default schema name (public) is also checked |
|
96 if dbhelper.backend_name == 'postgres': |
|
97 tables.update(t.lower() for t in dbhelper.list_tables(cnx.cnxset.cu, 'public')) |
95 has_computed_relations = 'cw_cwcomputedrtype' in tables |
98 has_computed_relations = 'cw_cwcomputedrtype' in tables |
96 # computed attribute |
99 # computed attribute |
97 try: |
100 try: |
98 cnx.system_sql("SELECT cw_formula FROM cw_CWAttribute") |
101 cnx.system_sql("SELECT cw_formula FROM cw_CWAttribute") |
99 has_computed_attributes = True |
102 has_computed_attributes = True |