Fix an issue where running any query in query tool gives 'list index out of range' error. #5922

This commit is contained in:
Aditya Toshniwal 2023-05-03 11:05:00 +05:30
parent 14f617681f
commit a73f58160f
2 changed files with 2 additions and 3 deletions

View File

@ -1390,7 +1390,7 @@ class ViewNode(PGChildNodeView, VacuumSettings, SchemaDiffObjectCompare):
for deftype in deftypes:
res[deftype] = \
parse_priv_to_db(res[row['deftype']], allowed_acls)
parse_priv_to_db(res[deftype], allowed_acls)
grant_sql = render_template("/".join(
[self.template_path, self._SQL_PREFIX + self._GRANT_SQL]),

View File

@ -60,8 +60,7 @@ def get_columns_types(is_query_tool, columns_info, table_oid, conn, has_oids):
col_type['has_default_val'] = \
col['has_default_val'] = row['has_default_val']
col_type['seqtypid'] = col['seqtypid'] = \
rset['rows'][key]['seqtypid']
col_type['seqtypid'] = col['seqtypid'] = row['seqtypid']
break
else: