Skip to content

Commit 54b8720

Browse files
authored
add amount of extract_columns and aliases to amount-mismatch compilation error message
1 parent fa4087e commit 54b8720

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

macros/internal/helpers/stage_processing_macros.sql

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,8 @@
145145
{# If column aliases are present they they have to map 1:1 to the extract_columns #}
146146
{% if datavault4dbt.is_something(dict_item.aliases)
147147
and not dict_item.aliases|length == dict_item.extract_columns|length %}
148-
{{ exceptions.raise_compiler_error("Prejoin aliases must have the same length as extract_columns") }}
148+
{{ exceptions.raise_compiler_error("Prejoin aliases must have the same length as extract_columns. Got "
149+
~ dict_item.extract_columns|length ~ " extract_columns and " ~ dict_item.aliases|length ~ " aliases.") }}
149150
{% endif %}
150151

151152
{# If multiple columns from the same source should be extracted each column has to be processed once #}

0 commit comments

Comments
 (0)