Skip to content

Commit

Permalink
Update snapshots to include new metric
Browse files Browse the repository at this point in the history
This impacts the unoptimized SQL for all queries using this semantic model
  • Loading branch information
courtneyholcomb committed Jul 30, 2024
1 parent f0c0b9e commit 4e60281
Show file tree
Hide file tree
Showing 36 changed files with 2,808 additions and 1,439 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ semantic_model:

defaults:
agg_time_dimension: created_at

dimensions:
- name: ds
type: time
Expand Down Expand Up @@ -53,4 +53,4 @@ semantic_model:
- name: new_users
expr: "1"
agg: SUM
create_metric: true
create_metric: true
Original file line number Diff line number Diff line change
Expand Up @@ -448,6 +448,7 @@
'user__listing__user__views_times_booking_value',
'user__listings',
'user__lux_listings',
'user__new_users',
'user__popular_listing_bookings_per_booker',
'user__regional_starting_balance_ratios',
'user__revenue',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
'max_booking_value',
'median_booking_value',
'min_booking_value',
'new_users',
'referred_bookings',
'smallest_listing',
'total_account_balance_first_day',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,7 @@ Model Join-Path Entity Links
('listings_latest',) ("('user',)", "('user',)") largest_listing ['JOINED', 'METRIC']
('listings_latest',) ("('user',)", "('user',)") listings ['JOINED', 'METRIC']
('listings_latest',) ("('user',)", "('user',)") lux_listings ['JOINED', 'METRIC']
('listings_latest',) ("('user',)", "('user',)") new_users ['JOINED', 'METRIC']
('listings_latest',) ("('user',)", "('user',)") popular_listing_bookings_per_booker ['JOINED', 'METRIC']
('listings_latest',) ("('user',)", "('user',)") regional_starting_balance_ratios ['JOINED', 'METRIC']
('listings_latest',) ("('user',)", "('user',)") revenue ['JOINED', 'METRIC']
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@
'company__user__company__largest_listing',
'company__user__company__listings',
'company__user__company__lux_listings',
'company__user__company__new_users',
'company__user__company__popular_listing_bookings_per_booker',
'company__user__company__regional_starting_balance_ratios',
'company__user__company__revenue',
Expand Down Expand Up @@ -559,6 +560,7 @@
'user__listing__user__views_times_booking_value',
'user__listings',
'user__lux_listings',
'user__new_users',
'user__popular_listing_bookings_per_booker',
'user__regional_starting_balance_ratios',
'user__revenue',
Expand Down
1 change: 0 additions & 1 deletion tests_metricflow/integration/test_cases/itest_metrics.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2265,4 +2265,3 @@ integration_test:
)
GROUP BY
subq_8.user__last_login_ts__minute
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@
<!-- node_id = NodeId(id_str='ss_28011') -->
<!-- col0 = -->
<!-- SqlSelectColumn( -->
<!-- expr=SqlStringExpression(node_id=str_28007 sql_expr=1), -->
<!-- expr=SqlStringExpression(node_id=str_28008 sql_expr=1), -->
<!-- column_alias='visits', -->
<!-- ) -->
<!-- col1 = -->
Expand Down Expand Up @@ -694,7 +694,7 @@
<!-- node_id = NodeId(id_str='ss_28011') -->
<!-- col0 = -->
<!-- SqlSelectColumn( -->
<!-- expr=SqlStringExpression(node_id=str_28007 sql_expr=1), -->
<!-- expr=SqlStringExpression(node_id=str_28008 sql_expr=1), -->
<!-- column_alias='visits', -->
<!-- ) -->
<!-- col1 = -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,7 @@
<!-- node_id = NodeId(id_str='ss_28011') -->
<!-- col0 = -->
<!-- SqlSelectColumn( -->
<!-- expr=SqlStringExpression(node_id=str_28007 sql_expr=1), -->
<!-- expr=SqlStringExpression(node_id=str_28008 sql_expr=1), -->
<!-- column_alias='visits', -->
<!-- ) -->
<!-- col1 = -->
Expand Down Expand Up @@ -860,7 +860,7 @@
<!-- node_id = NodeId(id_str='ss_28011') -->
<!-- col0 = -->
<!-- SqlSelectColumn( -->
<!-- expr=SqlStringExpression(node_id=str_28007 sql_expr=1), -->
<!-- expr=SqlStringExpression(node_id=str_28008 sql_expr=1), -->
<!-- column_alias='visits', -->
<!-- ) -->
<!-- col1 = -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@
<!-- node_id = NodeId(id_str='ss_28011') -->
<!-- col0 = -->
<!-- SqlSelectColumn( -->
<!-- expr=SqlStringExpression(node_id=str_28007 sql_expr=1), -->
<!-- expr=SqlStringExpression(node_id=str_28008 sql_expr=1), -->
<!-- column_alias='visits', -->
<!-- ) -->
<!-- col1 = -->
Expand Down Expand Up @@ -753,7 +753,7 @@
<!-- node_id = NodeId(id_str='ss_28011') -->
<!-- col0 = -->
<!-- SqlSelectColumn( -->
<!-- expr=SqlStringExpression(node_id=str_28007 sql_expr=1), -->
<!-- expr=SqlStringExpression(node_id=str_28008 sql_expr=1), -->
<!-- column_alias='visits', -->
<!-- ) -->
<!-- col1 = -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@
<!-- node_id = NodeId(id_str='ss_28011') -->
<!-- col0 = -->
<!-- SqlSelectColumn( -->
<!-- expr=SqlStringExpression(node_id=str_28007 sql_expr=1), -->
<!-- expr=SqlStringExpression(node_id=str_28008 sql_expr=1), -->
<!-- column_alias='visits', -->
<!-- ) -->
<!-- col1 = -->
Expand Down Expand Up @@ -813,7 +813,7 @@
<!-- node_id = NodeId(id_str='ss_28011') -->
<!-- col0 = -->
<!-- SqlSelectColumn( -->
<!-- expr=SqlStringExpression(node_id=str_28007 sql_expr=1), -->
<!-- expr=SqlStringExpression(node_id=str_28008 sql_expr=1), -->
<!-- column_alias='visits', -->
<!-- ) -->
<!-- col1 = -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@
<!-- node_id = NodeId(id_str='ss_28011') -->
<!-- col0 = -->
<!-- SqlSelectColumn( -->
<!-- expr=SqlStringExpression(node_id=str_28007 sql_expr=1), -->
<!-- expr=SqlStringExpression(node_id=str_28008 sql_expr=1), -->
<!-- column_alias='visits', -->
<!-- ) -->
<!-- col1 = -->
Expand Down Expand Up @@ -697,7 +697,7 @@
<!-- node_id = NodeId(id_str='ss_28011') -->
<!-- col0 = -->
<!-- SqlSelectColumn( -->
<!-- expr=SqlStringExpression(node_id=str_28007 sql_expr=1), -->
<!-- expr=SqlStringExpression(node_id=str_28008 sql_expr=1), -->
<!-- column_alias='visits', -->
<!-- ) -->
<!-- col1 = -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@
<!-- node_id = NodeId(id_str='ss_28011') -->
<!-- col0 = -->
<!-- SqlSelectColumn( -->
<!-- expr=SqlStringExpression(node_id=str_28007 sql_expr=1), -->
<!-- expr=SqlStringExpression(node_id=str_28008 sql_expr=1), -->
<!-- column_alias='visits', -->
<!-- ) -->
<!-- col1 = -->
Expand Down Expand Up @@ -801,7 +801,7 @@
<!-- node_id = NodeId(id_str='ss_28011') -->
<!-- col0 = -->
<!-- SqlSelectColumn( -->
<!-- expr=SqlStringExpression(node_id=str_28007 sql_expr=1), -->
<!-- expr=SqlStringExpression(node_id=str_28008 sql_expr=1), -->
<!-- column_alias='visits', -->
<!-- ) -->
<!-- col1 = -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@
<!-- distinct = False -->
<MetricTimeDimensionTransformNode>
<!-- description = "Metric Time Dimension 'ds'" -->
<!-- node_id = NodeId(id_str='sma_28014') -->
<!-- node_id = NodeId(id_str='sma_28015') -->
<!-- aggregation_time_dimension = 'ds' -->
<ReadSqlSourceNode>
<!-- description = "Read From SemanticModelDataSet('views_source')" -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2183,7 +2183,7 @@
<!-- node_id = NodeId(id_str='ss_28010') -->
<!-- col0 = -->
<!-- SqlSelectColumn( -->
<!-- expr=SqlStringExpression(node_id=str_28006 sql_expr=1), -->
<!-- expr=SqlStringExpression(node_id=str_28007 sql_expr=1), -->
<!-- column_alias='views', -->
<!-- ) -->
<!-- col1 = -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ SELECT
FROM (
-- Read Elements From Semantic Model 'users_ds_source'
SELECT
DATETIME_TRUNC(users_ds_source_src_28000.ds, day) AS ds__day
1 AS new_users
, DATETIME_TRUNC(users_ds_source_src_28000.ds, day) AS ds__day
, DATETIME_TRUNC(users_ds_source_src_28000.ds, isoweek) AS ds__week
, DATETIME_TRUNC(users_ds_source_src_28000.ds, month) AS ds__month
, DATETIME_TRUNC(users_ds_source_src_28000.ds, quarter) AS ds__quarter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ SELECT
FROM (
-- Read Elements From Semantic Model 'users_ds_source'
SELECT
DATE_TRUNC('day', users_ds_source_src_28000.ds) AS ds__day
1 AS new_users
, DATE_TRUNC('day', users_ds_source_src_28000.ds) AS ds__day
, DATE_TRUNC('week', users_ds_source_src_28000.ds) AS ds__week
, DATE_TRUNC('month', users_ds_source_src_28000.ds) AS ds__month
, DATE_TRUNC('quarter', users_ds_source_src_28000.ds) AS ds__quarter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ SELECT
FROM (
-- Read Elements From Semantic Model 'users_ds_source'
SELECT
DATE_TRUNC('day', users_ds_source_src_28000.ds) AS ds__day
1 AS new_users
, DATE_TRUNC('day', users_ds_source_src_28000.ds) AS ds__day
, DATE_TRUNC('week', users_ds_source_src_28000.ds) AS ds__week
, DATE_TRUNC('month', users_ds_source_src_28000.ds) AS ds__month
, DATE_TRUNC('quarter', users_ds_source_src_28000.ds) AS ds__quarter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ SELECT
FROM (
-- Read Elements From Semantic Model 'users_ds_source'
SELECT
DATE_TRUNC('day', users_ds_source_src_28000.ds) AS ds__day
1 AS new_users
, DATE_TRUNC('day', users_ds_source_src_28000.ds) AS ds__day
, DATE_TRUNC('week', users_ds_source_src_28000.ds) AS ds__week
, DATE_TRUNC('month', users_ds_source_src_28000.ds) AS ds__month
, DATE_TRUNC('quarter', users_ds_source_src_28000.ds) AS ds__quarter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ SELECT
FROM (
-- Read Elements From Semantic Model 'users_ds_source'
SELECT
DATE_TRUNC('day', users_ds_source_src_28000.ds) AS ds__day
1 AS new_users
, DATE_TRUNC('day', users_ds_source_src_28000.ds) AS ds__day
, DATE_TRUNC('week', users_ds_source_src_28000.ds) AS ds__week
, DATE_TRUNC('month', users_ds_source_src_28000.ds) AS ds__month
, DATE_TRUNC('quarter', users_ds_source_src_28000.ds) AS ds__quarter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ SELECT
FROM (
-- Read Elements From Semantic Model 'users_ds_source'
SELECT
DATE_TRUNC('day', users_ds_source_src_28000.ds) AS ds__day
1 AS new_users
, DATE_TRUNC('day', users_ds_source_src_28000.ds) AS ds__day
, DATE_TRUNC('week', users_ds_source_src_28000.ds) AS ds__week
, DATE_TRUNC('month', users_ds_source_src_28000.ds) AS ds__month
, DATE_TRUNC('quarter', users_ds_source_src_28000.ds) AS ds__quarter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ SELECT
FROM (
-- Read Elements From Semantic Model 'users_ds_source'
SELECT
DATE_TRUNC('day', users_ds_source_src_28000.ds) AS ds__day
1 AS new_users
, DATE_TRUNC('day', users_ds_source_src_28000.ds) AS ds__day
, DATE_TRUNC('week', users_ds_source_src_28000.ds) AS ds__week
, DATE_TRUNC('month', users_ds_source_src_28000.ds) AS ds__month
, DATE_TRUNC('quarter', users_ds_source_src_28000.ds) AS ds__quarter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@
<!-- distinct = False -->
<MetricTimeDimensionTransformNode>
<!-- description = "Metric Time Dimension 'ds'" -->
<!-- node_id = NodeId(id_str='sma_28015') -->
<!-- node_id = NodeId(id_str='sma_28016') -->
<!-- aggregation_time_dimension = 'ds' -->
<ReadSqlSourceNode>
<!-- description = "Read From SemanticModelDataSet('visits_source')" -->
Expand Down Expand Up @@ -257,7 +257,7 @@
<!-- ) -->
<MetricTimeDimensionTransformNode>
<!-- description = "Metric Time Dimension 'ds'" -->
<!-- node_id = NodeId(id_str='sma_28015') -->
<!-- node_id = NodeId(id_str='sma_28016') -->
<!-- aggregation_time_dimension = 'ds' -->
<ReadSqlSourceNode>
<!-- description = "Read From SemanticModelDataSet('visits_source')" -->
Expand Down
Loading

0 comments on commit 4e60281

Please sign in to comment.