From 52b4a7c4ab4919155b47468330171a963a0417bc Mon Sep 17 00:00:00 2001 From: Robby Robinson Date: Thu, 11 Apr 2024 16:14:04 -0700 Subject: [PATCH] made optional --- macros/plugins/snowflake/create_external_table.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/macros/plugins/snowflake/create_external_table.sql b/macros/plugins/snowflake/create_external_table.sql index ca32cf7..2a9b372 100644 --- a/macros/plugins/snowflake/create_external_table.sql +++ b/macros/plugins/snowflake/create_external_table.sql @@ -7,7 +7,7 @@ {% if infer_schema %} {% set query_infer_schema %} - select * from table( infer_schema( location=>'{{external.location}}', file_format=>'{{external.file_format}}', ignore_case=>{{external.ignore_case}} ) ) + select * from table( infer_schema( location=>'{{external.location}}', file_format=>'{{external.file_format}}'{%- if external.ignore_case -%}, ignore_case=>{{external.ignore_case}} {%- endif %} ) ) {% endset %} {% if execute %} {% set columns_infer = run_query(query_infer_schema) %}