dbt-firebolt 1.9.0__py3-none-any.whl → 1.9.1__py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
- dbt/adapters/firebolt/__init__.py +1 -1
- dbt/adapters/firebolt/connections.py +4 -2
- dbt/adapters/firebolt/impl.py +2 -3
- {dbt_firebolt-1.9.0.dist-info → dbt_firebolt-1.9.1.dist-info}/METADATA +2 -2
- dbt_firebolt-1.9.1.dist-info/RECORD +13 -0
- {dbt_firebolt-1.9.0.dist-info → dbt_firebolt-1.9.1.dist-info}/WHEEL +1 -1
- dbt/include/firebolt/dbt_project.yml +0 -6
- dbt/include/firebolt/macros/adapters/apply_grants.sql +0 -37
- dbt/include/firebolt/macros/adapters/relation.sql +0 -49
- dbt/include/firebolt/macros/adapters.sql +0 -197
- dbt/include/firebolt/macros/catalog.sql +0 -103
- dbt/include/firebolt/macros/dbt_external_tables/create_external_table.sql +0 -137
- dbt/include/firebolt/macros/dbt_external_tables/dropif.sql +0 -6
- dbt/include/firebolt/macros/dbt_external_tables/get_external_build_plan.sql +0 -18
- dbt/include/firebolt/macros/materializations/clone.sql +0 -3
- dbt/include/firebolt/macros/materializations/materialized_view.sql +0 -3
- dbt/include/firebolt/macros/materializations/models/incremental/column_helpers.sql +0 -21
- dbt/include/firebolt/macros/materializations/models/incremental/incremental.sql +0 -131
- dbt/include/firebolt/macros/materializations/models/incremental/is_incremental.sql +0 -14
- dbt/include/firebolt/macros/materializations/models/incremental/merge.sql +0 -38
- dbt/include/firebolt/macros/materializations/models/incremental/on_schema_change.sql +0 -90
- dbt/include/firebolt/macros/materializations/models/incremental/strategies.sql +0 -132
- dbt/include/firebolt/macros/materializations/seed.sql +0 -42
- dbt/include/firebolt/macros/materializations/snapshot_merge.sql +0 -19
- dbt/include/firebolt/macros/materializations/table.sql +0 -40
- dbt/include/firebolt/macros/materializations/test.sql +0 -15
- dbt/include/firebolt/macros/materializations/view.sql +0 -39
- dbt/include/firebolt/macros/relations/materialized_view/alter.sql +0 -11
- dbt/include/firebolt/macros/relations/materialized_view/create.sql +0 -3
- dbt/include/firebolt/macros/relations/materialized_view/describe.sql +0 -3
- dbt/include/firebolt/macros/relations/materialized_view/drop.sql +0 -3
- dbt/include/firebolt/macros/relations/materialized_view/refresh.sql +0 -3
- dbt/include/firebolt/macros/relations/table/create.sql +0 -78
- dbt/include/firebolt/macros/relations/table/drop.sql +0 -3
- dbt/include/firebolt/macros/relations/table/rename.sql +0 -6
- dbt/include/firebolt/macros/relations/table/replace.sql +0 -3
- dbt/include/firebolt/macros/relations/view/create.sql +0 -16
- dbt/include/firebolt/macros/relations/view/drop.sql +0 -3
- dbt/include/firebolt/macros/relations/view/rename.sql +0 -6
- dbt/include/firebolt/macros/relations/view/replace.sql +0 -3
- dbt/include/firebolt/macros/utils/array_append.sql +0 -3
- dbt/include/firebolt/macros/utils/array_concat.sql +0 -3
- dbt/include/firebolt/macros/utils/array_construct.sql +0 -3
- dbt/include/firebolt/macros/utils/bool_or.sql +0 -5
- dbt/include/firebolt/macros/utils/cast_bool_to_text.sql +0 -7
- dbt/include/firebolt/macros/utils/dateadd.sql +0 -9
- dbt/include/firebolt/macros/utils/datediff.sql +0 -9
- dbt/include/firebolt/macros/utils/except.sql +0 -6
- dbt/include/firebolt/macros/utils/intersect.sql +0 -6
- dbt/include/firebolt/macros/utils/listagg.sql +0 -27
- dbt/include/firebolt/macros/utils/position.sql +0 -3
- dbt/include/firebolt/macros/utils/right.sql +0 -12
- dbt/include/firebolt/macros/utils/split_part.sql +0 -14
- dbt/include/firebolt/macros/utils/timestamps.sql +0 -14
- dbt_firebolt-1.9.0.dist-info/RECORD +0 -61
- {dbt_firebolt-1.9.0.dist-info → dbt_firebolt-1.9.1.dist-info}/LICENSE +0 -0
- {dbt_firebolt-1.9.0.dist-info → dbt_firebolt-1.9.1.dist-info}/top_level.txt +0 -0
@@ -1,78 +0,0 @@
|
|
1
|
-
{% macro firebolt__create_table_as(
|
2
|
-
temporary,
|
3
|
-
relation,
|
4
|
-
select_sql,
|
5
|
-
language = 'sql'
|
6
|
-
) -%}
|
7
|
-
{# Create table using CTAS
|
8
|
-
Args:
|
9
|
-
temporary (bool): Unused, included so macro signature matches
|
10
|
-
that of dbt's default macro
|
11
|
-
relation (dbt relation/dict)
|
12
|
-
select_sql (string): The SQL query that will be used to generate
|
13
|
-
the internal query of the CTAS
|
14
|
-
language (string): sql or python models. Firebolt only supports sql.
|
15
|
-
#}
|
16
|
-
{%- if language == 'python' -%}
|
17
|
-
{{ exceptions.raise_compiler_error(
|
18
|
-
"Firebolt does not currently support " "Python models."
|
19
|
-
) }}
|
20
|
-
|
21
|
-
{%- elif language not in ['python', 'sql'] -%}
|
22
|
-
{{ exceptions.raise_compiler_error(
|
23
|
-
"Unexpected language parameter supplied: %s " "Must be either 'sql' or 'python'." % (language)
|
24
|
-
) }}
|
25
|
-
{%- endif -%}
|
26
|
-
|
27
|
-
{%- if temporary -%}
|
28
|
-
{%- do adapter.drop_relation(relation) -%}
|
29
|
-
{%- endif -%}
|
30
|
-
|
31
|
-
{%- set table_type = config.get(
|
32
|
-
'table_type',
|
33
|
-
default = 'dimension'
|
34
|
-
) | upper -%}
|
35
|
-
{%- set primary_index = config.get('primary_index') -%}
|
36
|
-
{%- set incremental_strategy = config.get('incremental_strategy') -%}
|
37
|
-
{%- set partitions = config.get('partition_by') %}
|
38
|
-
CREATE {{ table_type }} TABLE IF NOT EXISTS {{ relation }}
|
39
|
-
|
40
|
-
{%- set contract_config = config.get('contract') -%}
|
41
|
-
{%- if contract_config.enforced -%}
|
42
|
-
{{ get_assert_columns_equivalent(select_sql) }}
|
43
|
-
{{ get_table_columns_and_constraints() }};
|
44
|
-
INSERT INTO
|
45
|
-
{{ relation }}
|
46
|
-
(
|
47
|
-
{{ adapter.dispatch(
|
48
|
-
'get_column_names',
|
49
|
-
'dbt'
|
50
|
-
)() }}
|
51
|
-
) {%- set select_sql = get_select_subquery(select_sql) %}
|
52
|
-
{% endif %}
|
53
|
-
|
54
|
-
{%- if primary_index %}
|
55
|
-
primary INDEX {% if primary_index is iterable and primary_index is not string %}
|
56
|
-
"{{ primary_index | join('", "') }}"
|
57
|
-
{%- else -%}
|
58
|
-
"{{ primary_index }}"
|
59
|
-
{%- endif -%}
|
60
|
-
{%- endif -%}
|
61
|
-
|
62
|
-
{% if partitions %}
|
63
|
-
PARTITION BY {% if partitions is iterable and partitions is not string %}
|
64
|
-
{{ partitions | join(', ') }}
|
65
|
-
{%- else -%}
|
66
|
-
{{ partitions }}
|
67
|
-
{%- endif -%}
|
68
|
-
{%- endif %}
|
69
|
-
|
70
|
-
{%- if not contract_config.enforced %}
|
71
|
-
AS (
|
72
|
-
{% endif -%}
|
73
|
-
|
74
|
-
{{ select_sql }}
|
75
|
-
|
76
|
-
{% if not contract_config.enforced -%})
|
77
|
-
{%- endif -%}
|
78
|
-
{% endmacro %}
|
@@ -1,16 +0,0 @@
|
|
1
|
-
{% macro firebolt__create_view_as(
|
2
|
-
relation,
|
3
|
-
select_sql
|
4
|
-
) %}
|
5
|
-
CREATE
|
6
|
-
OR REPLACE VIEW {{ relation.identifier }}
|
7
|
-
|
8
|
-
{%- set contract_config = config.get('contract') -%}
|
9
|
-
{%- if contract_config.enforced -%}
|
10
|
-
{{ get_assert_columns_equivalent(select_sql) }}
|
11
|
-
{%- endif %}
|
12
|
-
|
13
|
-
AS (
|
14
|
-
{{ select_sql }}
|
15
|
-
)
|
16
|
-
{% endmacro %}
|
@@ -1,27 +0,0 @@
|
|
1
|
-
{% macro firebolt__listagg(measure, delimiter_text, order_by_clause, limit_num) -%}
|
2
|
-
|
3
|
-
{% if order_by_clause -%}
|
4
|
-
|
5
|
-
{{ exceptions.raise_compiler_error("Firebolt does not currently support "
|
6
|
-
"ARRAY_AGG with ORDER BY clause.") }}
|
7
|
-
|
8
|
-
{%- endif %}
|
9
|
-
|
10
|
-
{% if limit_num -%}
|
11
|
-
|
12
|
-
ARRAY_JOIN(
|
13
|
-
SLICE(
|
14
|
-
ARRAY_AGG({{ measure }})
|
15
|
-
0,
|
16
|
-
{{ limit_num }}
|
17
|
-
),
|
18
|
-
{{ delimiter_text }}
|
19
|
-
)
|
20
|
-
|
21
|
-
{%- else %}
|
22
|
-
|
23
|
-
ARRAY_JOIN(ARRAY_AGG({{ measure }}), {{ delimiter_text }})
|
24
|
-
|
25
|
-
{%- endif %}
|
26
|
-
|
27
|
-
{%- endmacro %}
|
@@ -1,14 +0,0 @@
|
|
1
|
-
{% macro firebolt__split_part(string_text, delimiter_text, part_number) %}
|
2
|
-
|
3
|
-
{% if delimiter_text.startswith("'") and delimiter_text.endswith("'") -%}
|
4
|
-
SPLIT_PART(
|
5
|
-
{{ string_text }},
|
6
|
-
{{ delimiter_text }},
|
7
|
-
{{ part_number }}
|
8
|
-
)
|
9
|
-
{%- else %}
|
10
|
-
{{ exceptions.raise_compiler_error("Firebolt does not currently support "
|
11
|
-
"reading delimiter from a column.") }}
|
12
|
-
|
13
|
-
{%- endif %}
|
14
|
-
{% endmacro %}
|
@@ -1,14 +0,0 @@
|
|
1
|
-
{% macro firebolt__current_timestamp() %}
|
2
|
-
NOW()
|
3
|
-
{% endmacro %}
|
4
|
-
|
5
|
-
|
6
|
-
{# TODO: Do we still need this?
|
7
|
-
See https://packboard.atlassian.net/browse/FIR-12156 #}
|
8
|
-
{% macro firebolt__snapshot_string_as_time(timestamp) -%}
|
9
|
-
{% call statement('timestamp', fetch_result=True) %}
|
10
|
-
|
11
|
-
SELECT CAST('{{ timestamp }}' AS DATE)
|
12
|
-
{% endcall %}
|
13
|
-
{{ return(load_result('timestamp').table) }}
|
14
|
-
{% endmacro %}
|
@@ -1,61 +0,0 @@
|
|
1
|
-
dbt/adapters/firebolt/__init__.py,sha256=JjZII9vG02tYg2Mx_VhNAvHCmaGklk5xXNQhOpqQcOM,411
|
2
|
-
dbt/adapters/firebolt/__version__.py,sha256=zRlZGglif76ZVuWWSjsH_MMPgtVQqmj-SryYJW25FL4,69
|
3
|
-
dbt/adapters/firebolt/column.py,sha256=COo_wjhCFgS3GFcPIPcoq7WAWgzN6DB2XqG-gk51WBc,539
|
4
|
-
dbt/adapters/firebolt/connections.py,sha256=_i0wPE6LWmLGo_C50UhPAU8IMUi_I2HU23fBZtfhi0Q,7942
|
5
|
-
dbt/adapters/firebolt/impl.py,sha256=xlmGCDezIsUKiQ4gQFR60h_QtvSgW1lOacktv8Lt3ow,15143
|
6
|
-
dbt/adapters/firebolt/relation.py,sha256=Xg3Nrjw3UrF_qwnuGbPT97rSXRiDP1GlIAoBF4b7QnY,1922
|
7
|
-
dbt/adapters/firebolt/relation_configs/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
8
|
-
dbt/include/firebolt/__init__.py,sha256=vBGWeG-dHHkimfnX8axBJ4IgAowFw8xADmo6Auzn2xc,52
|
9
|
-
dbt/include/firebolt/dbt_project.yml,sha256=uHJ-i0wD1D74DWSSSzsFKoKbAN1w4LBgVpnkm8e-M1g,76
|
10
|
-
dbt/include/firebolt/macros/adapters.sql,sha256=NiTW87XQmC8gGahY6LCw7Fd6Brgin5qBO1qqVef9YWQ,6848
|
11
|
-
dbt/include/firebolt/macros/catalog.sql,sha256=LLhjI9oEoMEQKQfE3LJ5nWS9-u3bwBAYBz4ukrsg5T8,3350
|
12
|
-
dbt/include/firebolt/macros/adapters/apply_grants.sql,sha256=nEmyDs0K0HENxxMaY8v-5oifIXDMrysmuUb_bo9bCuY,1095
|
13
|
-
dbt/include/firebolt/macros/adapters/relation.sql,sha256=1nQZg_vwpGYwFI2EQvHJA5CqFWk7h3w3Yq2uvYXNR5E,2017
|
14
|
-
dbt/include/firebolt/macros/dbt_external_tables/create_external_table.sql,sha256=MeFyR0oMjQdc0GlUABx6DDm5t76PdcdmXKWGVThi4EE,6069
|
15
|
-
dbt/include/firebolt/macros/dbt_external_tables/dropif.sql,sha256=-kZzUVgC6Bcof7tZ9VcDK427agylMHeG-yA8NqSeWkw,167
|
16
|
-
dbt/include/firebolt/macros/dbt_external_tables/get_external_build_plan.sql,sha256=BWNSuqB9t0hxbxL9CbIc0UFTBBarQMtGfHv9LLAbqSI,894
|
17
|
-
dbt/include/firebolt/macros/materializations/clone.sql,sha256=SKPc_tG0tF2HRKlo1-CQPvxVWGKHpXDwxvubsCwKTG8,79
|
18
|
-
dbt/include/firebolt/macros/materializations/materialized_view.sql,sha256=pdWGMP25o0RqNINx1hbn1Q4dTNcdk0Dgrlv3K8XQAbs,202
|
19
|
-
dbt/include/firebolt/macros/materializations/seed.sql,sha256=O622lwmzRGeAfaNfRpjR183ARFltILteznwgXZfPXMA,1564
|
20
|
-
dbt/include/firebolt/macros/materializations/snapshot_merge.sql,sha256=9Y4tGWkqkBDt53QHKxJPFALboKQxDJ4ZaSrLwNyRgIs,795
|
21
|
-
dbt/include/firebolt/macros/materializations/table.sql,sha256=XY0D-df9EoWOBF3kCT3TCE3Rko7bvvfuztQT0-Pqlfs,1752
|
22
|
-
dbt/include/firebolt/macros/materializations/test.sql,sha256=Wol19pNIfkPRTpVUYKAGbkipYOMZjixnAaoZ1chuP88,488
|
23
|
-
dbt/include/firebolt/macros/materializations/view.sql,sha256=0xg2mO-1UWtZKj2Wlplgm7s93l-FKBswajiBOqPu2Og,1706
|
24
|
-
dbt/include/firebolt/macros/materializations/models/incremental/column_helpers.sql,sha256=7XQsKdqcnKaIUxll4Etfa59HtF-3R3NfeSgpavBSJQE,917
|
25
|
-
dbt/include/firebolt/macros/materializations/models/incremental/incremental.sql,sha256=bd8f-O9KPo5wpL9MpKDHxTJ8wAjT7BOxyUFybR9MPu8,5905
|
26
|
-
dbt/include/firebolt/macros/materializations/models/incremental/is_incremental.sql,sha256=8Zgg0wOgIDQK_SAwxi7zk7gr_6Q7WyqN8nflTYpoyG0,581
|
27
|
-
dbt/include/firebolt/macros/materializations/models/incremental/merge.sql,sha256=YPryPkUfVVrKVk5bSdGt0eMa5NdFMMvJW1OuQ6o2umw,1311
|
28
|
-
dbt/include/firebolt/macros/materializations/models/incremental/on_schema_change.sql,sha256=WxGhX22oJRhDVsR4nUWilCSIG-bb7efDC3AXcU8VbbQ,3933
|
29
|
-
dbt/include/firebolt/macros/materializations/models/incremental/strategies.sql,sha256=GvqmGbwuxbAY9FBQp3XGzabHWINUaBM8CxVY-aLn4Jk,5928
|
30
|
-
dbt/include/firebolt/macros/relations/materialized_view/alter.sql,sha256=QDMCFwJZZfz7mrx6UcyDICSWAS3zQTs52_urcsW8klU,286
|
31
|
-
dbt/include/firebolt/macros/relations/materialized_view/create.sql,sha256=xthF0oHCyC4xu8IKEtoLJIyWh3p-JGBS5Awc3J-sQ8Y,178
|
32
|
-
dbt/include/firebolt/macros/relations/materialized_view/describe.sql,sha256=uMJWY-9P-49YjhwH_F1Co4szia0oNAVYqJIv2IVGzM8,164
|
33
|
-
dbt/include/firebolt/macros/relations/materialized_view/drop.sql,sha256=Ya03cid5h05t3-SIF4JndKtMMIctD46OX9gPVt9jhVw,160
|
34
|
-
dbt/include/firebolt/macros/relations/materialized_view/refresh.sql,sha256=9s4e6cjT9Dx9nCCJPMlhV5SkzHX8574cdIJUhSfNmU8,163
|
35
|
-
dbt/include/firebolt/macros/relations/table/create.sql,sha256=5FK3XOICE-9LGojHzh0pjCy5wO-RKyeytzkEQmYT7zY,2507
|
36
|
-
dbt/include/firebolt/macros/relations/table/drop.sql,sha256=3W0SMqmlDizmZqn-QZvqXeJ9lG2KtooiFvwac3WzSzQ,110
|
37
|
-
dbt/include/firebolt/macros/relations/table/rename.sql,sha256=5dmKvuiSnMTARuthnDJBUOORdQCIeEuGMLoyZlgQxVU,185
|
38
|
-
dbt/include/firebolt/macros/relations/table/replace.sql,sha256=bw08YDtLMhkM4dO4nYXZ32U50lcnTG5Axb-Lls7XpB0,132
|
39
|
-
dbt/include/firebolt/macros/relations/view/create.sql,sha256=WXXMS_WnHCoeWdYmyq7DWWeeoLag2ylXBxoltaCzIFA,333
|
40
|
-
dbt/include/firebolt/macros/relations/view/drop.sql,sha256=8m_CtJrFXY_vZM9EEYi7_7kCuXKtc0ql_9S_cmKVEb8,112
|
41
|
-
dbt/include/firebolt/macros/relations/view/rename.sql,sha256=3PkhAm3E4VscNSj2jM2kGGcSC9NGM9gJreSRS0rAFbI,183
|
42
|
-
dbt/include/firebolt/macros/relations/view/replace.sql,sha256=dszxLtQPuhZCEYeuqnuheu0HfN1RZoY05b34fMweEEg,123
|
43
|
-
dbt/include/firebolt/macros/utils/array_append.sql,sha256=woAedZFXFYh6TYXwJQCxKj4o5yo71yXBdk-nxcF4Kss,117
|
44
|
-
dbt/include/firebolt/macros/utils/array_concat.sql,sha256=Q9yY_rhcITJH0bS12MJOkBl5PXJ-ScgFZTBrqmQtdmw,117
|
45
|
-
dbt/include/firebolt/macros/utils/array_construct.sql,sha256=C1I8STXIEN4-Ms6_b1Fw7QqzaAiesjC3M4RWa6e3pBY,105
|
46
|
-
dbt/include/firebolt/macros/utils/bool_or.sql,sha256=NzL7uWbQIi1hUkIeshnEHIfQOVIW-gTLHU1QzTkToNQ,87
|
47
|
-
dbt/include/firebolt/macros/utils/cast_bool_to_text.sql,sha256=ZUst68Bx6Xuls2TO2BjDkBUS1gj0z7upZwvF4r6cmN0,187
|
48
|
-
dbt/include/firebolt/macros/utils/dateadd.sql,sha256=5xRi047b42aOYpCLnVPuQa3wXN9k1-3xNC4ta5p9AEA,202
|
49
|
-
dbt/include/firebolt/macros/utils/datediff.sql,sha256=cy-Ex1TOyddF23JnvqprOVFeCEpag_wTvNazEh7BURY,214
|
50
|
-
dbt/include/firebolt/macros/utils/except.sql,sha256=AoIC6Lr9_qMpD3dNw0Fp_wqtT2nM3WhbvF8drHKx_zQ,186
|
51
|
-
dbt/include/firebolt/macros/utils/intersect.sql,sha256=b8T-mB_qXgHN7dHTy0iA5oX029EPnyNfphW_96j0c94,192
|
52
|
-
dbt/include/firebolt/macros/utils/listagg.sql,sha256=ncnvHyiD_S4cdAxU05_yIftkqc3mS6FB6742hyXG1ns,588
|
53
|
-
dbt/include/firebolt/macros/utils/position.sql,sha256=WPo9_bhvNYJooEAsHC9OcnNAwUChRe5m02Rt0MpWqFA,129
|
54
|
-
dbt/include/firebolt/macros/utils/right.sql,sha256=_mm1_2MvlOH4O6CmYhgvVxMLfDxAvgv-EMwZ8OBOq-I,254
|
55
|
-
dbt/include/firebolt/macros/utils/split_part.sql,sha256=5dUlbx3Pt1iWWaIlxiXyYUwUqzXuLLXMB-1aGJHNk4o,464
|
56
|
-
dbt/include/firebolt/macros/utils/timestamps.sql,sha256=22g-QpJjBuBUQOHNpQ_TuMRa-cHxaxXPv8ItEUo-vEk,397
|
57
|
-
dbt_firebolt-1.9.0.dist-info/LICENSE,sha256=Nn0EGvW3qmoZpBV_JVM3iPukFf3RiNCIizrWe_2oTHk,11354
|
58
|
-
dbt_firebolt-1.9.0.dist-info/METADATA,sha256=cusaAXb1pygjqHsGIE6sk-Xk56vD8NOhOnVzWhWn-_M,5237
|
59
|
-
dbt_firebolt-1.9.0.dist-info/WHEEL,sha256=oiQVh_5PnQM0E3gPdiz09WCNmwiHDMaGer_elqB3coM,92
|
60
|
-
dbt_firebolt-1.9.0.dist-info/top_level.txt,sha256=B2YH4he17ajilEWOGCKHbRcEJlCuZKwCcgFcLPntLsE,4
|
61
|
-
dbt_firebolt-1.9.0.dist-info/RECORD,,
|
File without changes
|
File without changes
|