We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 7efdedd + 32d40e3 commit facf917Copy full SHA for facf917
macros/sql/union.sql
@@ -9,9 +9,13 @@
9
10
{%- set _ = table_columns.update({table: []}) %}
11
12
- {%- set table_parts = table.split('.') %}
+ {%- if table.name -%}
13
+ {%- set schema, table_name = table.schema, table.name -%}
14
+ {%- else -%}
15
+ {%- set schema, table_name = (table | string).split(".") -%}
16
+ {%- endif -%}
17
- {%- set cols = adapter.get_columns_in_table(*table_parts) %}
18
+ {%- set cols = adapter.get_columns_in_table(schema, table_name) %}
19
{%- for col in cols -%}
20
21
{# update the list of columns in this table #}
0 commit comments