-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #8 from bqbooster/output_dataset
Add default output dataset & table with extension options values
- Loading branch information
Showing
5 changed files
with
82 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
models/global/datamart/dbt_bigquery_monitoring_options.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
{{ | ||
config( | ||
materialized='table', | ||
) | ||
}} | ||
|
||
{%- set options = [ | ||
'bq_region', | ||
'input_gcp_projects', | ||
'output_dataset', | ||
'use_flat_pricing', | ||
'per_billed_tb_price', | ||
'free_tb_per_month', | ||
'hourly_slot_price', | ||
'prefer_physical_pricing_model', | ||
'active_logical_storage_gb_price', | ||
'long_term_logical_storage_gb_price', | ||
'active_physical_storage_gb_price', | ||
'long_term_physical_storage_gb_price', | ||
'free_storage_gb_per_month', | ||
'bi_engine_gb_hourly_price', | ||
'lookback_window_days', | ||
'output_materialization', | ||
'output_limit_size', | ||
] %} | ||
|
||
{% for option in options %} | ||
SELECT "{{ option }}" as option_label, "{{ var(option) }}" as option_value | ||
{% if not loop.last %} | ||
UNION ALL | ||
{% endif %} | ||
{% endfor %} |
10 changes: 10 additions & 0 deletions
10
models/global/datamart/dbt_bigquery_monitoring_options.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
version: 2 | ||
|
||
models: | ||
- name: bigquery_monitoring_options | ||
description: This model contains current configuration options and values for dbt BigQuery monitoring extension. | ||
columns: | ||
- name: option_label | ||
description: The label of the configuration option. | ||
- name: option_value | ||
description: The value of the configuration option. |