Skip to content

Commit

Permalink
fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
signedav committed Sep 26, 2023
1 parent 599e8d5 commit 254e918
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions modelbaker/dbconnector/pg_connector.py
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ def get_tables_info(self):
# if something of this topic where the current class is located has been extended, it gets the next child topic.
# the relevant topics for optimization are the ones that are not more extended (or in the very last class).
topics = """(SELECT STRING_AGG(childTopic,',') FROM {topic_pedigree}) as all_topics,
(SELECT STRING_AGG(childTopic,',') FROM {topic_pedigree} WHERE NOT is_a_base) as relevant_topics""".format(
(SELECT STRING_AGG(childTopic,',') FROM {topic_pedigree} WHERE NOT is_a_base) as relevant_topics,""".format(
topic_pedigree="""(WITH RECURSIVE children(is_a_base, childTopic, baseTopic) AS (
SELECT
(CASE
Expand Down Expand Up @@ -304,10 +304,10 @@ def get_tables_info(self):
{extent}
{attribute_name}
{coord_decimals}
g.type AS simple_type,
format_type(ga.atttypid, ga.atttypmod) as formatted_type,
{relevance}
{topics}
g.type AS simple_type,
format_type(ga.atttypid, ga.atttypmod) as formatted_type
FROM pg_catalog.pg_tables tbls
LEFT JOIN pg_index i
ON i.indrelid = CONCAT(tbls.schemaname, '."', tbls.tablename, '"')::regclass
Expand Down

0 comments on commit 254e918

Please sign in to comment.