From bc331595d2da9960634d8c1cee02ad01cf3822ef Mon Sep 17 00:00:00 2001 From: Vinh Pham Date: Sun, 24 Sep 2023 21:52:53 +0700 Subject: [PATCH] Add spark identifier --- macros/utils.sql | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/macros/utils.sql b/macros/utils.sql index 0277802..082da6e 100644 --- a/macros/utils.sql +++ b/macros/utils.sql @@ -191,6 +191,14 @@ {% endif %} {%- endmacro %} +{% macro spark__quote_identifier(identifier) %} + {% if identifier.startswith('`') %} + {{ return(identifier) }} + {% else %} + {{ return('`' ~ identifier ~ '`') }} + {% endif %} +{% endmacro %} + {% macro bigquery__quote_identifier(identifier) %} {% if identifier.startswith('`') %} {{ return(identifier) }}