Financial rate metrics
This commit is contained in:
parent
ea430b1f23
commit
5ac1a65e90
5 changed files with 26 additions and 17 deletions
|
|
@ -4,7 +4,7 @@ with
|
|||
)
|
||||
select
|
||||
id_exchange_rate as id_exchange_rate,
|
||||
from_currency as from_currency,
|
||||
from_currency collate "en_US.utf8" as from_currency,
|
||||
to_currency as to_currency,
|
||||
rate as rate,
|
||||
rate_date_utc as rate_date_utc,
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
with
|
||||
dimensions as (
|
||||
{% for dimension in production_dimensions %}
|
||||
select
|
||||
select
|
||||
{{ dimension.dimension }} as dimension,
|
||||
{{ dimension.dimension_display }} as dimension_display
|
||||
{% if not loop.last %}
|
||||
|
|
@ -12,15 +12,12 @@ with
|
|||
{% endfor %}
|
||||
),
|
||||
int_mtd_aggregated_metrics as (
|
||||
select
|
||||
m.*,
|
||||
d.dimension_display
|
||||
select m.*, d.dimension_display
|
||||
from {{ ref("int_mtd_aggregated_metrics") }} m
|
||||
-- The following clause limits the display execution
|
||||
-- to only include those dimensions configured to
|
||||
-- appear for production purposes
|
||||
inner join dimensions d
|
||||
on m.dimension = d.dimension
|
||||
inner join dimensions d on m.dimension = d.dimension
|
||||
)
|
||||
|
||||
select
|
||||
|
|
|
|||
|
|
@ -405,7 +405,13 @@ models:
|
|||
description: Allows for grouping and formatting for displaying purposes.
|
||||
tests:
|
||||
- accepted_values:
|
||||
values: ["integer", "percentage", "currency_gbp"]
|
||||
values:
|
||||
[
|
||||
"integer",
|
||||
"percentage",
|
||||
"currency_gbp",
|
||||
"converted_metric_currency_gbp",
|
||||
]
|
||||
|
||||
- name: value
|
||||
data_type: numeric
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue