diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_dimensions_with_time_constraint__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_dimensions_with_time_constraint__plan0.sql index d79391ab01..98928afa92 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_dimensions_with_time_constraint__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_dimensions_with_time_constraint__plan0.sql @@ -218,18 +218,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATETIME_TRUNC(time_spine_src_28000.ds, day) AS ds__day - , DATETIME_TRUNC(time_spine_src_28000.ds, isoweek) AS ds__week - , DATETIME_TRUNC(time_spine_src_28000.ds, month) AS ds__month - , DATETIME_TRUNC(time_spine_src_28000.ds, quarter) AS ds__quarter - , DATETIME_TRUNC(time_spine_src_28000.ds, year) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , IF(EXTRACT(dayofweek FROM time_spine_src_28000.ds) = 1, 7, EXTRACT(dayofweek FROM time_spine_src_28000.ds) - 1) AS ds__extract_dow - , EXTRACT(dayofyear FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATETIME_TRUNC(time_spine_src_28006.ds, day) AS ds__day + , DATETIME_TRUNC(time_spine_src_28006.ds, isoweek) AS ds__week + , DATETIME_TRUNC(time_spine_src_28006.ds, month) AS ds__month + , DATETIME_TRUNC(time_spine_src_28006.ds, quarter) AS ds__quarter + , DATETIME_TRUNC(time_spine_src_28006.ds, year) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , IF(EXTRACT(dayofweek FROM time_spine_src_28006.ds) = 1, 7, EXTRACT(dayofweek FROM time_spine_src_28006.ds) - 1) AS ds__extract_dow + , EXTRACT(dayofyear FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_1 ) subq_2 ) subq_3 diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_dimensions_with_time_constraint__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_dimensions_with_time_constraint__plan0_optimized.sql index e939afb66d..ee11e39060 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_dimensions_with_time_constraint__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_dimensions_with_time_constraint__plan0_optimized.sql @@ -2,17 +2,17 @@ -- Constrain Time Range to [2020-01-01T00:00:00, 2020-01-03T00:00:00] -- Pass Only Elements: ['user__home_state_latest', 'listing__is_lux_latest', 'metric_time__day'] SELECT - DATETIME_TRUNC(time_spine_src_28000.ds, day) AS metric_time__day + DATETIME_TRUNC(time_spine_src_28006.ds, day) AS metric_time__day , listings_latest_src_28000.is_lux AS listing__is_lux_latest , users_latest_src_28000.home_state_latest AS user__home_state_latest FROM ***************************.dim_listings_latest listings_latest_src_28000 CROSS JOIN - ***************************.mf_time_spine time_spine_src_28000 + ***************************.mf_time_spine time_spine_src_28006 FULL OUTER JOIN ***************************.dim_users_latest users_latest_src_28000 ON listings_latest_src_28000.user_id = users_latest_src_28000.user_id -WHERE DATETIME_TRUNC(time_spine_src_28000.ds, day) BETWEEN '2020-01-01' AND '2020-01-03' +WHERE DATETIME_TRUNC(time_spine_src_28006.ds, day) BETWEEN '2020-01-01' AND '2020-01-03' GROUP BY metric_time__day , listing__is_lux_latest diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_only__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_only__plan0.sql index a5ac99c303..7c7c84cde3 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_only__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_only__plan0.sql @@ -29,18 +29,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATETIME_TRUNC(time_spine_src_28000.ds, day) AS ds__day - , DATETIME_TRUNC(time_spine_src_28000.ds, isoweek) AS ds__week - , DATETIME_TRUNC(time_spine_src_28000.ds, month) AS ds__month - , DATETIME_TRUNC(time_spine_src_28000.ds, quarter) AS ds__quarter - , DATETIME_TRUNC(time_spine_src_28000.ds, year) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , IF(EXTRACT(dayofweek FROM time_spine_src_28000.ds) = 1, 7, EXTRACT(dayofweek FROM time_spine_src_28000.ds) - 1) AS ds__extract_dow - , EXTRACT(dayofyear FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATETIME_TRUNC(time_spine_src_28006.ds, day) AS ds__day + , DATETIME_TRUNC(time_spine_src_28006.ds, isoweek) AS ds__week + , DATETIME_TRUNC(time_spine_src_28006.ds, month) AS ds__month + , DATETIME_TRUNC(time_spine_src_28006.ds, quarter) AS ds__quarter + , DATETIME_TRUNC(time_spine_src_28006.ds, year) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , IF(EXTRACT(dayofweek FROM time_spine_src_28006.ds) = 1, 7, EXTRACT(dayofweek FROM time_spine_src_28006.ds) - 1) AS ds__extract_dow + , EXTRACT(dayofyear FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_only__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_only__plan0_optimized.sql index e3d2c86221..aefc098bd3 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_only__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_only__plan0_optimized.sql @@ -3,6 +3,6 @@ -- Pass Only Elements: ['metric_time__day',] SELECT DATETIME_TRUNC(ds, day) AS metric_time__day -FROM ***************************.mf_time_spine time_spine_src_28000 +FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY metric_time__day diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_quarter_alone__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_quarter_alone__plan0.sql index 46093b139a..0e8fd5fcfc 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_quarter_alone__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_quarter_alone__plan0.sql @@ -29,18 +29,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATETIME_TRUNC(time_spine_src_28000.ds, day) AS ds__day - , DATETIME_TRUNC(time_spine_src_28000.ds, isoweek) AS ds__week - , DATETIME_TRUNC(time_spine_src_28000.ds, month) AS ds__month - , DATETIME_TRUNC(time_spine_src_28000.ds, quarter) AS ds__quarter - , DATETIME_TRUNC(time_spine_src_28000.ds, year) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , IF(EXTRACT(dayofweek FROM time_spine_src_28000.ds) = 1, 7, EXTRACT(dayofweek FROM time_spine_src_28000.ds) - 1) AS ds__extract_dow - , EXTRACT(dayofyear FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATETIME_TRUNC(time_spine_src_28006.ds, day) AS ds__day + , DATETIME_TRUNC(time_spine_src_28006.ds, isoweek) AS ds__week + , DATETIME_TRUNC(time_spine_src_28006.ds, month) AS ds__month + , DATETIME_TRUNC(time_spine_src_28006.ds, quarter) AS ds__quarter + , DATETIME_TRUNC(time_spine_src_28006.ds, year) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , IF(EXTRACT(dayofweek FROM time_spine_src_28006.ds) = 1, 7, EXTRACT(dayofweek FROM time_spine_src_28006.ds) - 1) AS ds__extract_dow + , EXTRACT(dayofyear FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_quarter_alone__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_quarter_alone__plan0_optimized.sql index 7f99e4d431..81ede48103 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_quarter_alone__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_quarter_alone__plan0_optimized.sql @@ -3,6 +3,6 @@ -- Pass Only Elements: ['metric_time__quarter',] SELECT DATETIME_TRUNC(ds, quarter) AS metric_time__quarter -FROM ***************************.mf_time_spine time_spine_src_28000 +FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY metric_time__quarter diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_with_other_dimensions__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_with_other_dimensions__plan0.sql index f8d8755c47..161bc57c9f 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_with_other_dimensions__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_with_other_dimensions__plan0.sql @@ -157,18 +157,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATETIME_TRUNC(time_spine_src_28000.ds, day) AS ds__day - , DATETIME_TRUNC(time_spine_src_28000.ds, isoweek) AS ds__week - , DATETIME_TRUNC(time_spine_src_28000.ds, month) AS ds__month - , DATETIME_TRUNC(time_spine_src_28000.ds, quarter) AS ds__quarter - , DATETIME_TRUNC(time_spine_src_28000.ds, year) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , IF(EXTRACT(dayofweek FROM time_spine_src_28000.ds) = 1, 7, EXTRACT(dayofweek FROM time_spine_src_28000.ds) - 1) AS ds__extract_dow - , EXTRACT(dayofyear FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATETIME_TRUNC(time_spine_src_28006.ds, day) AS ds__day + , DATETIME_TRUNC(time_spine_src_28006.ds, isoweek) AS ds__week + , DATETIME_TRUNC(time_spine_src_28006.ds, month) AS ds__month + , DATETIME_TRUNC(time_spine_src_28006.ds, quarter) AS ds__quarter + , DATETIME_TRUNC(time_spine_src_28006.ds, year) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , IF(EXTRACT(dayofweek FROM time_spine_src_28006.ds) = 1, 7, EXTRACT(dayofweek FROM time_spine_src_28006.ds) - 1) AS ds__extract_dow + , EXTRACT(dayofyear FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_1 ) subq_2 ) subq_3 diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_with_other_dimensions__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_with_other_dimensions__plan0_optimized.sql index 0ab00225f9..f03a3399ee 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_with_other_dimensions__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/BigQuery/test_metric_time_with_other_dimensions__plan0_optimized.sql @@ -1,12 +1,12 @@ -- Join Standard Outputs -- Pass Only Elements: ['user__home_state_latest', 'listing__is_lux_latest', 'metric_time__day'] SELECT - DATETIME_TRUNC(time_spine_src_28000.ds, day) AS metric_time__day + DATETIME_TRUNC(time_spine_src_28006.ds, day) AS metric_time__day , listings_latest_src_28000.is_lux AS listing__is_lux_latest , users_latest_src_28000.home_state_latest AS user__home_state_latest FROM ***************************.dim_listings_latest listings_latest_src_28000 CROSS JOIN - ***************************.mf_time_spine time_spine_src_28000 + ***************************.mf_time_spine time_spine_src_28006 FULL OUTER JOIN ***************************.dim_users_latest users_latest_src_28000 ON diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_dimensions_with_time_constraint__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_dimensions_with_time_constraint__plan0.sql index c158a74935..f28a1aed0c 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_dimensions_with_time_constraint__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_dimensions_with_time_constraint__plan0.sql @@ -218,18 +218,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(DAYOFWEEK_ISO FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(DAYOFWEEK_ISO FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_1 ) subq_2 ) subq_3 diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_dimensions_with_time_constraint__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_dimensions_with_time_constraint__plan0_optimized.sql index 96a96bb787..f7f473a317 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_dimensions_with_time_constraint__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_dimensions_with_time_constraint__plan0_optimized.sql @@ -2,18 +2,18 @@ -- Constrain Time Range to [2020-01-01T00:00:00, 2020-01-03T00:00:00] -- Pass Only Elements: ['user__home_state_latest', 'listing__is_lux_latest', 'metric_time__day'] SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS metric_time__day + DATE_TRUNC('day', time_spine_src_28006.ds) AS metric_time__day , listings_latest_src_28000.is_lux AS listing__is_lux_latest , users_latest_src_28000.home_state_latest AS user__home_state_latest FROM ***************************.dim_listings_latest listings_latest_src_28000 CROSS JOIN - ***************************.mf_time_spine time_spine_src_28000 + ***************************.mf_time_spine time_spine_src_28006 FULL OUTER JOIN ***************************.dim_users_latest users_latest_src_28000 ON listings_latest_src_28000.user_id = users_latest_src_28000.user_id -WHERE DATE_TRUNC('day', time_spine_src_28000.ds) BETWEEN '2020-01-01' AND '2020-01-03' +WHERE DATE_TRUNC('day', time_spine_src_28006.ds) BETWEEN '2020-01-01' AND '2020-01-03' GROUP BY - DATE_TRUNC('day', time_spine_src_28000.ds) + DATE_TRUNC('day', time_spine_src_28006.ds) , listings_latest_src_28000.is_lux , users_latest_src_28000.home_state_latest diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_only__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_only__plan0.sql index 12f243442c..27ff087a4a 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_only__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_only__plan0.sql @@ -29,18 +29,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(DAYOFWEEK_ISO FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(DAYOFWEEK_ISO FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_only__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_only__plan0_optimized.sql index 2eed8d0c4b..ec27d0d54a 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_only__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_only__plan0_optimized.sql @@ -3,6 +3,6 @@ -- Pass Only Elements: ['metric_time__day',] SELECT DATE_TRUNC('day', ds) AS metric_time__day -FROM ***************************.mf_time_spine time_spine_src_28000 +FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('day', ds) diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_quarter_alone__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_quarter_alone__plan0.sql index 5f56894a6b..939c04fbd5 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_quarter_alone__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_quarter_alone__plan0.sql @@ -29,18 +29,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(DAYOFWEEK_ISO FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(DAYOFWEEK_ISO FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_quarter_alone__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_quarter_alone__plan0_optimized.sql index 89d1d3d730..d33ecb7c33 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_quarter_alone__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_quarter_alone__plan0_optimized.sql @@ -3,6 +3,6 @@ -- Pass Only Elements: ['metric_time__quarter',] SELECT DATE_TRUNC('quarter', ds) AS metric_time__quarter -FROM ***************************.mf_time_spine time_spine_src_28000 +FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('quarter', ds) diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_with_other_dimensions__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_with_other_dimensions__plan0.sql index 5ec23f6eba..3bb8f19c72 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_with_other_dimensions__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_with_other_dimensions__plan0.sql @@ -157,18 +157,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(DAYOFWEEK_ISO FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(DAYOFWEEK_ISO FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_1 ) subq_2 ) subq_3 diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_with_other_dimensions__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_with_other_dimensions__plan0_optimized.sql index f029b6173e..68e7b122d2 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_with_other_dimensions__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Databricks/test_metric_time_with_other_dimensions__plan0_optimized.sql @@ -1,17 +1,17 @@ -- Join Standard Outputs -- Pass Only Elements: ['user__home_state_latest', 'listing__is_lux_latest', 'metric_time__day'] SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS metric_time__day + DATE_TRUNC('day', time_spine_src_28006.ds) AS metric_time__day , listings_latest_src_28000.is_lux AS listing__is_lux_latest , users_latest_src_28000.home_state_latest AS user__home_state_latest FROM ***************************.dim_listings_latest listings_latest_src_28000 CROSS JOIN - ***************************.mf_time_spine time_spine_src_28000 + ***************************.mf_time_spine time_spine_src_28006 FULL OUTER JOIN ***************************.dim_users_latest users_latest_src_28000 ON listings_latest_src_28000.user_id = users_latest_src_28000.user_id GROUP BY - DATE_TRUNC('day', time_spine_src_28000.ds) + DATE_TRUNC('day', time_spine_src_28006.ds) , listings_latest_src_28000.is_lux , users_latest_src_28000.home_state_latest diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_dimensions_with_time_constraint__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_dimensions_with_time_constraint__plan0.sql index 1e42a5d726..4fa1768bc7 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_dimensions_with_time_constraint__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_dimensions_with_time_constraint__plan0.sql @@ -218,18 +218,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(isodow FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(isodow FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_1 ) subq_2 ) subq_3 diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_dimensions_with_time_constraint__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_dimensions_with_time_constraint__plan0_optimized.sql index 96a96bb787..f7f473a317 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_dimensions_with_time_constraint__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_dimensions_with_time_constraint__plan0_optimized.sql @@ -2,18 +2,18 @@ -- Constrain Time Range to [2020-01-01T00:00:00, 2020-01-03T00:00:00] -- Pass Only Elements: ['user__home_state_latest', 'listing__is_lux_latest', 'metric_time__day'] SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS metric_time__day + DATE_TRUNC('day', time_spine_src_28006.ds) AS metric_time__day , listings_latest_src_28000.is_lux AS listing__is_lux_latest , users_latest_src_28000.home_state_latest AS user__home_state_latest FROM ***************************.dim_listings_latest listings_latest_src_28000 CROSS JOIN - ***************************.mf_time_spine time_spine_src_28000 + ***************************.mf_time_spine time_spine_src_28006 FULL OUTER JOIN ***************************.dim_users_latest users_latest_src_28000 ON listings_latest_src_28000.user_id = users_latest_src_28000.user_id -WHERE DATE_TRUNC('day', time_spine_src_28000.ds) BETWEEN '2020-01-01' AND '2020-01-03' +WHERE DATE_TRUNC('day', time_spine_src_28006.ds) BETWEEN '2020-01-01' AND '2020-01-03' GROUP BY - DATE_TRUNC('day', time_spine_src_28000.ds) + DATE_TRUNC('day', time_spine_src_28006.ds) , listings_latest_src_28000.is_lux , users_latest_src_28000.home_state_latest diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_only__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_only__plan0.sql index c6bb4bb18f..b7efe020e7 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_only__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_only__plan0.sql @@ -29,18 +29,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(isodow FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(isodow FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_only__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_only__plan0_optimized.sql index 2eed8d0c4b..ec27d0d54a 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_only__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_only__plan0_optimized.sql @@ -3,6 +3,6 @@ -- Pass Only Elements: ['metric_time__day',] SELECT DATE_TRUNC('day', ds) AS metric_time__day -FROM ***************************.mf_time_spine time_spine_src_28000 +FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('day', ds) diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_quarter_alone__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_quarter_alone__plan0.sql index a1584ad35b..a719a46832 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_quarter_alone__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_quarter_alone__plan0.sql @@ -29,18 +29,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(isodow FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(isodow FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_quarter_alone__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_quarter_alone__plan0_optimized.sql index 89d1d3d730..d33ecb7c33 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_quarter_alone__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_quarter_alone__plan0_optimized.sql @@ -3,6 +3,6 @@ -- Pass Only Elements: ['metric_time__quarter',] SELECT DATE_TRUNC('quarter', ds) AS metric_time__quarter -FROM ***************************.mf_time_spine time_spine_src_28000 +FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('quarter', ds) diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_with_other_dimensions__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_with_other_dimensions__plan0.sql index 44f88a1efd..0ca186e4af 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_with_other_dimensions__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_with_other_dimensions__plan0.sql @@ -157,18 +157,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(isodow FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(isodow FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_1 ) subq_2 ) subq_3 diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_with_other_dimensions__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_with_other_dimensions__plan0_optimized.sql index f029b6173e..68e7b122d2 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_with_other_dimensions__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Postgres/test_metric_time_with_other_dimensions__plan0_optimized.sql @@ -1,17 +1,17 @@ -- Join Standard Outputs -- Pass Only Elements: ['user__home_state_latest', 'listing__is_lux_latest', 'metric_time__day'] SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS metric_time__day + DATE_TRUNC('day', time_spine_src_28006.ds) AS metric_time__day , listings_latest_src_28000.is_lux AS listing__is_lux_latest , users_latest_src_28000.home_state_latest AS user__home_state_latest FROM ***************************.dim_listings_latest listings_latest_src_28000 CROSS JOIN - ***************************.mf_time_spine time_spine_src_28000 + ***************************.mf_time_spine time_spine_src_28006 FULL OUTER JOIN ***************************.dim_users_latest users_latest_src_28000 ON listings_latest_src_28000.user_id = users_latest_src_28000.user_id GROUP BY - DATE_TRUNC('day', time_spine_src_28000.ds) + DATE_TRUNC('day', time_spine_src_28006.ds) , listings_latest_src_28000.is_lux , users_latest_src_28000.home_state_latest diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_dimensions_with_time_constraint__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_dimensions_with_time_constraint__plan0.sql index 5d4572d904..c3937910b2 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_dimensions_with_time_constraint__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_dimensions_with_time_constraint__plan0.sql @@ -218,18 +218,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , CASE WHEN EXTRACT(dow FROM time_spine_src_28000.ds) = 0 THEN EXTRACT(dow FROM time_spine_src_28000.ds) + 7 ELSE EXTRACT(dow FROM time_spine_src_28000.ds) END AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , CASE WHEN EXTRACT(dow FROM time_spine_src_28006.ds) = 0 THEN EXTRACT(dow FROM time_spine_src_28006.ds) + 7 ELSE EXTRACT(dow FROM time_spine_src_28006.ds) END AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_1 ) subq_2 ) subq_3 diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_dimensions_with_time_constraint__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_dimensions_with_time_constraint__plan0_optimized.sql index 96a96bb787..f7f473a317 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_dimensions_with_time_constraint__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_dimensions_with_time_constraint__plan0_optimized.sql @@ -2,18 +2,18 @@ -- Constrain Time Range to [2020-01-01T00:00:00, 2020-01-03T00:00:00] -- Pass Only Elements: ['user__home_state_latest', 'listing__is_lux_latest', 'metric_time__day'] SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS metric_time__day + DATE_TRUNC('day', time_spine_src_28006.ds) AS metric_time__day , listings_latest_src_28000.is_lux AS listing__is_lux_latest , users_latest_src_28000.home_state_latest AS user__home_state_latest FROM ***************************.dim_listings_latest listings_latest_src_28000 CROSS JOIN - ***************************.mf_time_spine time_spine_src_28000 + ***************************.mf_time_spine time_spine_src_28006 FULL OUTER JOIN ***************************.dim_users_latest users_latest_src_28000 ON listings_latest_src_28000.user_id = users_latest_src_28000.user_id -WHERE DATE_TRUNC('day', time_spine_src_28000.ds) BETWEEN '2020-01-01' AND '2020-01-03' +WHERE DATE_TRUNC('day', time_spine_src_28006.ds) BETWEEN '2020-01-01' AND '2020-01-03' GROUP BY - DATE_TRUNC('day', time_spine_src_28000.ds) + DATE_TRUNC('day', time_spine_src_28006.ds) , listings_latest_src_28000.is_lux , users_latest_src_28000.home_state_latest diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_only__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_only__plan0.sql index 00fc8c8a34..f2ad087708 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_only__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_only__plan0.sql @@ -29,18 +29,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , CASE WHEN EXTRACT(dow FROM time_spine_src_28000.ds) = 0 THEN EXTRACT(dow FROM time_spine_src_28000.ds) + 7 ELSE EXTRACT(dow FROM time_spine_src_28000.ds) END AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , CASE WHEN EXTRACT(dow FROM time_spine_src_28006.ds) = 0 THEN EXTRACT(dow FROM time_spine_src_28006.ds) + 7 ELSE EXTRACT(dow FROM time_spine_src_28006.ds) END AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_only__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_only__plan0_optimized.sql index 2eed8d0c4b..ec27d0d54a 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_only__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_only__plan0_optimized.sql @@ -3,6 +3,6 @@ -- Pass Only Elements: ['metric_time__day',] SELECT DATE_TRUNC('day', ds) AS metric_time__day -FROM ***************************.mf_time_spine time_spine_src_28000 +FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('day', ds) diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_quarter_alone__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_quarter_alone__plan0.sql index d60589cfc7..a4f3a0d479 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_quarter_alone__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_quarter_alone__plan0.sql @@ -29,18 +29,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , CASE WHEN EXTRACT(dow FROM time_spine_src_28000.ds) = 0 THEN EXTRACT(dow FROM time_spine_src_28000.ds) + 7 ELSE EXTRACT(dow FROM time_spine_src_28000.ds) END AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , CASE WHEN EXTRACT(dow FROM time_spine_src_28006.ds) = 0 THEN EXTRACT(dow FROM time_spine_src_28006.ds) + 7 ELSE EXTRACT(dow FROM time_spine_src_28006.ds) END AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_quarter_alone__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_quarter_alone__plan0_optimized.sql index 89d1d3d730..d33ecb7c33 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_quarter_alone__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_quarter_alone__plan0_optimized.sql @@ -3,6 +3,6 @@ -- Pass Only Elements: ['metric_time__quarter',] SELECT DATE_TRUNC('quarter', ds) AS metric_time__quarter -FROM ***************************.mf_time_spine time_spine_src_28000 +FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('quarter', ds) diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_with_other_dimensions__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_with_other_dimensions__plan0.sql index 801a5743f3..fdaa63698b 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_with_other_dimensions__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_with_other_dimensions__plan0.sql @@ -157,18 +157,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , CASE WHEN EXTRACT(dow FROM time_spine_src_28000.ds) = 0 THEN EXTRACT(dow FROM time_spine_src_28000.ds) + 7 ELSE EXTRACT(dow FROM time_spine_src_28000.ds) END AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , CASE WHEN EXTRACT(dow FROM time_spine_src_28006.ds) = 0 THEN EXTRACT(dow FROM time_spine_src_28006.ds) + 7 ELSE EXTRACT(dow FROM time_spine_src_28006.ds) END AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_1 ) subq_2 ) subq_3 diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_with_other_dimensions__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_with_other_dimensions__plan0_optimized.sql index f029b6173e..68e7b122d2 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_with_other_dimensions__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Redshift/test_metric_time_with_other_dimensions__plan0_optimized.sql @@ -1,17 +1,17 @@ -- Join Standard Outputs -- Pass Only Elements: ['user__home_state_latest', 'listing__is_lux_latest', 'metric_time__day'] SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS metric_time__day + DATE_TRUNC('day', time_spine_src_28006.ds) AS metric_time__day , listings_latest_src_28000.is_lux AS listing__is_lux_latest , users_latest_src_28000.home_state_latest AS user__home_state_latest FROM ***************************.dim_listings_latest listings_latest_src_28000 CROSS JOIN - ***************************.mf_time_spine time_spine_src_28000 + ***************************.mf_time_spine time_spine_src_28006 FULL OUTER JOIN ***************************.dim_users_latest users_latest_src_28000 ON listings_latest_src_28000.user_id = users_latest_src_28000.user_id GROUP BY - DATE_TRUNC('day', time_spine_src_28000.ds) + DATE_TRUNC('day', time_spine_src_28006.ds) , listings_latest_src_28000.is_lux , users_latest_src_28000.home_state_latest diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_dimensions_with_time_constraint__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_dimensions_with_time_constraint__plan0.sql index 98667582a9..7fc222ee66 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_dimensions_with_time_constraint__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_dimensions_with_time_constraint__plan0.sql @@ -218,18 +218,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(dayofweekiso FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(dayofweekiso FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_1 ) subq_2 ) subq_3 diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_dimensions_with_time_constraint__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_dimensions_with_time_constraint__plan0_optimized.sql index 96a96bb787..f7f473a317 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_dimensions_with_time_constraint__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_dimensions_with_time_constraint__plan0_optimized.sql @@ -2,18 +2,18 @@ -- Constrain Time Range to [2020-01-01T00:00:00, 2020-01-03T00:00:00] -- Pass Only Elements: ['user__home_state_latest', 'listing__is_lux_latest', 'metric_time__day'] SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS metric_time__day + DATE_TRUNC('day', time_spine_src_28006.ds) AS metric_time__day , listings_latest_src_28000.is_lux AS listing__is_lux_latest , users_latest_src_28000.home_state_latest AS user__home_state_latest FROM ***************************.dim_listings_latest listings_latest_src_28000 CROSS JOIN - ***************************.mf_time_spine time_spine_src_28000 + ***************************.mf_time_spine time_spine_src_28006 FULL OUTER JOIN ***************************.dim_users_latest users_latest_src_28000 ON listings_latest_src_28000.user_id = users_latest_src_28000.user_id -WHERE DATE_TRUNC('day', time_spine_src_28000.ds) BETWEEN '2020-01-01' AND '2020-01-03' +WHERE DATE_TRUNC('day', time_spine_src_28006.ds) BETWEEN '2020-01-01' AND '2020-01-03' GROUP BY - DATE_TRUNC('day', time_spine_src_28000.ds) + DATE_TRUNC('day', time_spine_src_28006.ds) , listings_latest_src_28000.is_lux , users_latest_src_28000.home_state_latest diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_only__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_only__plan0.sql index 5d5be88b9e..d3dc52558a 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_only__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_only__plan0.sql @@ -29,18 +29,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(dayofweekiso FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(dayofweekiso FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_only__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_only__plan0_optimized.sql index 2eed8d0c4b..ec27d0d54a 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_only__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_only__plan0_optimized.sql @@ -3,6 +3,6 @@ -- Pass Only Elements: ['metric_time__day',] SELECT DATE_TRUNC('day', ds) AS metric_time__day -FROM ***************************.mf_time_spine time_spine_src_28000 +FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('day', ds) diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_quarter_alone__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_quarter_alone__plan0.sql index 636a1ecd16..2f076adedb 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_quarter_alone__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_quarter_alone__plan0.sql @@ -29,18 +29,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(dayofweekiso FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(dayofweekiso FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_quarter_alone__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_quarter_alone__plan0_optimized.sql index 89d1d3d730..d33ecb7c33 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_quarter_alone__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_quarter_alone__plan0_optimized.sql @@ -3,6 +3,6 @@ -- Pass Only Elements: ['metric_time__quarter',] SELECT DATE_TRUNC('quarter', ds) AS metric_time__quarter -FROM ***************************.mf_time_spine time_spine_src_28000 +FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('quarter', ds) diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_with_other_dimensions__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_with_other_dimensions__plan0.sql index a5c5e24b30..0b393e86b3 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_with_other_dimensions__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_with_other_dimensions__plan0.sql @@ -157,18 +157,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(dayofweekiso FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(dayofweekiso FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_1 ) subq_2 ) subq_3 diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_with_other_dimensions__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_with_other_dimensions__plan0_optimized.sql index f029b6173e..68e7b122d2 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_with_other_dimensions__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Snowflake/test_metric_time_with_other_dimensions__plan0_optimized.sql @@ -1,17 +1,17 @@ -- Join Standard Outputs -- Pass Only Elements: ['user__home_state_latest', 'listing__is_lux_latest', 'metric_time__day'] SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS metric_time__day + DATE_TRUNC('day', time_spine_src_28006.ds) AS metric_time__day , listings_latest_src_28000.is_lux AS listing__is_lux_latest , users_latest_src_28000.home_state_latest AS user__home_state_latest FROM ***************************.dim_listings_latest listings_latest_src_28000 CROSS JOIN - ***************************.mf_time_spine time_spine_src_28000 + ***************************.mf_time_spine time_spine_src_28006 FULL OUTER JOIN ***************************.dim_users_latest users_latest_src_28000 ON listings_latest_src_28000.user_id = users_latest_src_28000.user_id GROUP BY - DATE_TRUNC('day', time_spine_src_28000.ds) + DATE_TRUNC('day', time_spine_src_28006.ds) , listings_latest_src_28000.is_lux , users_latest_src_28000.home_state_latest diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_dimensions_with_time_constraint__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_dimensions_with_time_constraint__plan0.sql index 89ae3ebda3..2cd56fbc7e 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_dimensions_with_time_constraint__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_dimensions_with_time_constraint__plan0.sql @@ -218,18 +218,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(DAY_OF_WEEK FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(DAY_OF_WEEK FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_1 ) subq_2 ) subq_3 diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_dimensions_with_time_constraint__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_dimensions_with_time_constraint__plan0_optimized.sql index 864a5c757f..cd1bf9a23e 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_dimensions_with_time_constraint__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_dimensions_with_time_constraint__plan0_optimized.sql @@ -2,18 +2,18 @@ -- Constrain Time Range to [2020-01-01T00:00:00, 2020-01-03T00:00:00] -- Pass Only Elements: ['user__home_state_latest', 'listing__is_lux_latest', 'metric_time__day'] SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS metric_time__day + DATE_TRUNC('day', time_spine_src_28006.ds) AS metric_time__day , listings_latest_src_28000.is_lux AS listing__is_lux_latest , users_latest_src_28000.home_state_latest AS user__home_state_latest FROM ***************************.dim_listings_latest listings_latest_src_28000 CROSS JOIN - ***************************.mf_time_spine time_spine_src_28000 + ***************************.mf_time_spine time_spine_src_28006 FULL OUTER JOIN ***************************.dim_users_latest users_latest_src_28000 ON listings_latest_src_28000.user_id = users_latest_src_28000.user_id -WHERE DATE_TRUNC('day', time_spine_src_28000.ds) BETWEEN timestamp '2020-01-01' AND timestamp '2020-01-03' +WHERE DATE_TRUNC('day', time_spine_src_28006.ds) BETWEEN timestamp '2020-01-01' AND timestamp '2020-01-03' GROUP BY - DATE_TRUNC('day', time_spine_src_28000.ds) + DATE_TRUNC('day', time_spine_src_28006.ds) , listings_latest_src_28000.is_lux , users_latest_src_28000.home_state_latest diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_only__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_only__plan0.sql index 863f81b097..3c0778b8c2 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_only__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_only__plan0.sql @@ -29,18 +29,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(DAY_OF_WEEK FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(DAY_OF_WEEK FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_only__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_only__plan0_optimized.sql index 2eed8d0c4b..ec27d0d54a 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_only__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_only__plan0_optimized.sql @@ -3,6 +3,6 @@ -- Pass Only Elements: ['metric_time__day',] SELECT DATE_TRUNC('day', ds) AS metric_time__day -FROM ***************************.mf_time_spine time_spine_src_28000 +FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('day', ds) diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_quarter_alone__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_quarter_alone__plan0.sql index e2652152ca..d18942fc1e 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_quarter_alone__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_quarter_alone__plan0.sql @@ -29,18 +29,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(DAY_OF_WEEK FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(DAY_OF_WEEK FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_quarter_alone__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_quarter_alone__plan0_optimized.sql index 89d1d3d730..d33ecb7c33 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_quarter_alone__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_quarter_alone__plan0_optimized.sql @@ -3,6 +3,6 @@ -- Pass Only Elements: ['metric_time__quarter',] SELECT DATE_TRUNC('quarter', ds) AS metric_time__quarter -FROM ***************************.mf_time_spine time_spine_src_28000 +FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('quarter', ds) diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_with_other_dimensions__plan0.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_with_other_dimensions__plan0.sql index 99af6dace4..1c5714bc87 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_with_other_dimensions__plan0.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_with_other_dimensions__plan0.sql @@ -157,18 +157,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(DAY_OF_WEEK FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(DAY_OF_WEEK FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_1 ) subq_2 ) subq_3 diff --git a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_with_other_dimensions__plan0_optimized.sql b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_with_other_dimensions__plan0_optimized.sql index f029b6173e..68e7b122d2 100644 --- a/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_with_other_dimensions__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_metric_time_without_metrics.py/SqlQueryPlan/Trino/test_metric_time_with_other_dimensions__plan0_optimized.sql @@ -1,17 +1,17 @@ -- Join Standard Outputs -- Pass Only Elements: ['user__home_state_latest', 'listing__is_lux_latest', 'metric_time__day'] SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS metric_time__day + DATE_TRUNC('day', time_spine_src_28006.ds) AS metric_time__day , listings_latest_src_28000.is_lux AS listing__is_lux_latest , users_latest_src_28000.home_state_latest AS user__home_state_latest FROM ***************************.dim_listings_latest listings_latest_src_28000 CROSS JOIN - ***************************.mf_time_spine time_spine_src_28000 + ***************************.mf_time_spine time_spine_src_28006 FULL OUTER JOIN ***************************.dim_users_latest users_latest_src_28000 ON listings_latest_src_28000.user_id = users_latest_src_28000.user_id GROUP BY - DATE_TRUNC('day', time_spine_src_28000.ds) + DATE_TRUNC('day', time_spine_src_28006.ds) , listings_latest_src_28000.is_lux , users_latest_src_28000.home_state_latest diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time__plan0.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time__plan0.sql index 43cd6f32e3..9366489873 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time__plan0.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time__plan0.sql @@ -34,18 +34,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATETIME_TRUNC(time_spine_src_28000.ds, day) AS ds__day - , DATETIME_TRUNC(time_spine_src_28000.ds, isoweek) AS ds__week - , DATETIME_TRUNC(time_spine_src_28000.ds, month) AS ds__month - , DATETIME_TRUNC(time_spine_src_28000.ds, quarter) AS ds__quarter - , DATETIME_TRUNC(time_spine_src_28000.ds, year) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , IF(EXTRACT(dayofweek FROM time_spine_src_28000.ds) = 1, 7, EXTRACT(dayofweek FROM time_spine_src_28000.ds) - 1) AS ds__extract_dow - , EXTRACT(dayofyear FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATETIME_TRUNC(time_spine_src_28006.ds, day) AS ds__day + , DATETIME_TRUNC(time_spine_src_28006.ds, isoweek) AS ds__week + , DATETIME_TRUNC(time_spine_src_28006.ds, month) AS ds__month + , DATETIME_TRUNC(time_spine_src_28006.ds, quarter) AS ds__quarter + , DATETIME_TRUNC(time_spine_src_28006.ds, year) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , IF(EXTRACT(dayofweek FROM time_spine_src_28006.ds) = 1, 7, EXTRACT(dayofweek FROM time_spine_src_28006.ds) - 1) AS ds__extract_dow + , EXTRACT(dayofyear FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time__plan0_optimized.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time__plan0_optimized.sql index 21b0a95fc4..f24a9803be 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time__plan0_optimized.sql @@ -8,7 +8,7 @@ FROM ( -- Pass Only Elements: ['metric_time__day',] SELECT DATETIME_TRUNC(ds, day) AS metric_time__day - FROM ***************************.mf_time_spine time_spine_src_28000 + FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY metric_time__day ) subq_5 diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time_week__plan0.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time_week__plan0.sql index f43945c4af..a020f1aad3 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time_week__plan0.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time_week__plan0.sql @@ -34,18 +34,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATETIME_TRUNC(time_spine_src_28000.ds, day) AS ds__day - , DATETIME_TRUNC(time_spine_src_28000.ds, isoweek) AS ds__week - , DATETIME_TRUNC(time_spine_src_28000.ds, month) AS ds__month - , DATETIME_TRUNC(time_spine_src_28000.ds, quarter) AS ds__quarter - , DATETIME_TRUNC(time_spine_src_28000.ds, year) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , IF(EXTRACT(dayofweek FROM time_spine_src_28000.ds) = 1, 7, EXTRACT(dayofweek FROM time_spine_src_28000.ds) - 1) AS ds__extract_dow - , EXTRACT(dayofyear FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATETIME_TRUNC(time_spine_src_28006.ds, day) AS ds__day + , DATETIME_TRUNC(time_spine_src_28006.ds, isoweek) AS ds__week + , DATETIME_TRUNC(time_spine_src_28006.ds, month) AS ds__month + , DATETIME_TRUNC(time_spine_src_28006.ds, quarter) AS ds__quarter + , DATETIME_TRUNC(time_spine_src_28006.ds, year) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , IF(EXTRACT(dayofweek FROM time_spine_src_28006.ds) = 1, 7, EXTRACT(dayofweek FROM time_spine_src_28006.ds) - 1) AS ds__extract_dow + , EXTRACT(dayofyear FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time_week__plan0_optimized.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time_week__plan0_optimized.sql index 68ca95b0d3..02d3002c6c 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time_week__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/BigQuery/test_min_max_metric_time_week__plan0_optimized.sql @@ -8,7 +8,7 @@ FROM ( -- Pass Only Elements: ['metric_time__week',] SELECT DATETIME_TRUNC(ds, isoweek) AS metric_time__week - FROM ***************************.mf_time_spine time_spine_src_28000 + FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY metric_time__week ) subq_5 diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time__plan0.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time__plan0.sql index dbfc7da23a..829d13678f 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time__plan0.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time__plan0.sql @@ -34,18 +34,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(DAYOFWEEK_ISO FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(DAYOFWEEK_ISO FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time__plan0_optimized.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time__plan0_optimized.sql index ce2a27035e..4d31ef04b9 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time__plan0_optimized.sql @@ -8,7 +8,7 @@ FROM ( -- Pass Only Elements: ['metric_time__day',] SELECT DATE_TRUNC('day', ds) AS metric_time__day - FROM ***************************.mf_time_spine time_spine_src_28000 + FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('day', ds) ) subq_5 diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time_week__plan0.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time_week__plan0.sql index d7ca5161cc..68dd51363f 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time_week__plan0.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time_week__plan0.sql @@ -34,18 +34,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(DAYOFWEEK_ISO FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(DAYOFWEEK_ISO FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time_week__plan0_optimized.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time_week__plan0_optimized.sql index a5d07eba96..4ceb83d067 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time_week__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Databricks/test_min_max_metric_time_week__plan0_optimized.sql @@ -8,7 +8,7 @@ FROM ( -- Pass Only Elements: ['metric_time__week',] SELECT DATE_TRUNC('week', ds) AS metric_time__week - FROM ***************************.mf_time_spine time_spine_src_28000 + FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('week', ds) ) subq_5 diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time__plan0.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time__plan0.sql index fecf550869..0eef091ea3 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time__plan0.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time__plan0.sql @@ -34,18 +34,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(isodow FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(isodow FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time__plan0_optimized.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time__plan0_optimized.sql index ce2a27035e..4d31ef04b9 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time__plan0_optimized.sql @@ -8,7 +8,7 @@ FROM ( -- Pass Only Elements: ['metric_time__day',] SELECT DATE_TRUNC('day', ds) AS metric_time__day - FROM ***************************.mf_time_spine time_spine_src_28000 + FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('day', ds) ) subq_5 diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time_week__plan0.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time_week__plan0.sql index 8216c96cc1..7c587e39ac 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time_week__plan0.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time_week__plan0.sql @@ -34,18 +34,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(isodow FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(isodow FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time_week__plan0_optimized.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time_week__plan0_optimized.sql index a5d07eba96..4ceb83d067 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time_week__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Postgres/test_min_max_metric_time_week__plan0_optimized.sql @@ -8,7 +8,7 @@ FROM ( -- Pass Only Elements: ['metric_time__week',] SELECT DATE_TRUNC('week', ds) AS metric_time__week - FROM ***************************.mf_time_spine time_spine_src_28000 + FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('week', ds) ) subq_5 diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time__plan0.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time__plan0.sql index 5f3939ae42..5d35c8a3ba 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time__plan0.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time__plan0.sql @@ -34,18 +34,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , CASE WHEN EXTRACT(dow FROM time_spine_src_28000.ds) = 0 THEN EXTRACT(dow FROM time_spine_src_28000.ds) + 7 ELSE EXTRACT(dow FROM time_spine_src_28000.ds) END AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , CASE WHEN EXTRACT(dow FROM time_spine_src_28006.ds) = 0 THEN EXTRACT(dow FROM time_spine_src_28006.ds) + 7 ELSE EXTRACT(dow FROM time_spine_src_28006.ds) END AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time__plan0_optimized.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time__plan0_optimized.sql index ce2a27035e..4d31ef04b9 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time__plan0_optimized.sql @@ -8,7 +8,7 @@ FROM ( -- Pass Only Elements: ['metric_time__day',] SELECT DATE_TRUNC('day', ds) AS metric_time__day - FROM ***************************.mf_time_spine time_spine_src_28000 + FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('day', ds) ) subq_5 diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time_week__plan0.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time_week__plan0.sql index a78f290fde..1bd5e2e330 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time_week__plan0.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time_week__plan0.sql @@ -34,18 +34,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , CASE WHEN EXTRACT(dow FROM time_spine_src_28000.ds) = 0 THEN EXTRACT(dow FROM time_spine_src_28000.ds) + 7 ELSE EXTRACT(dow FROM time_spine_src_28000.ds) END AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , CASE WHEN EXTRACT(dow FROM time_spine_src_28006.ds) = 0 THEN EXTRACT(dow FROM time_spine_src_28006.ds) + 7 ELSE EXTRACT(dow FROM time_spine_src_28006.ds) END AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time_week__plan0_optimized.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time_week__plan0_optimized.sql index a5d07eba96..4ceb83d067 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time_week__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Redshift/test_min_max_metric_time_week__plan0_optimized.sql @@ -8,7 +8,7 @@ FROM ( -- Pass Only Elements: ['metric_time__week',] SELECT DATE_TRUNC('week', ds) AS metric_time__week - FROM ***************************.mf_time_spine time_spine_src_28000 + FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('week', ds) ) subq_5 diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time__plan0.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time__plan0.sql index 8532ab4bbb..6d1f296f9d 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time__plan0.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time__plan0.sql @@ -34,18 +34,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(dayofweekiso FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(dayofweekiso FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time__plan0_optimized.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time__plan0_optimized.sql index ce2a27035e..4d31ef04b9 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time__plan0_optimized.sql @@ -8,7 +8,7 @@ FROM ( -- Pass Only Elements: ['metric_time__day',] SELECT DATE_TRUNC('day', ds) AS metric_time__day - FROM ***************************.mf_time_spine time_spine_src_28000 + FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('day', ds) ) subq_5 diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time_week__plan0.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time_week__plan0.sql index b761f97a62..9f37f05bc2 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time_week__plan0.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time_week__plan0.sql @@ -34,18 +34,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(dayofweekiso FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(dayofweekiso FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time_week__plan0_optimized.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time_week__plan0_optimized.sql index a5d07eba96..4ceb83d067 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time_week__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Snowflake/test_min_max_metric_time_week__plan0_optimized.sql @@ -8,7 +8,7 @@ FROM ( -- Pass Only Elements: ['metric_time__week',] SELECT DATE_TRUNC('week', ds) AS metric_time__week - FROM ***************************.mf_time_spine time_spine_src_28000 + FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('week', ds) ) subq_5 diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time__plan0.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time__plan0.sql index ce97454651..0f0357e2e0 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time__plan0.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time__plan0.sql @@ -34,18 +34,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(DAY_OF_WEEK FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(DAY_OF_WEEK FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time__plan0_optimized.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time__plan0_optimized.sql index ce2a27035e..4d31ef04b9 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time__plan0_optimized.sql @@ -8,7 +8,7 @@ FROM ( -- Pass Only Elements: ['metric_time__day',] SELECT DATE_TRUNC('day', ds) AS metric_time__day - FROM ***************************.mf_time_spine time_spine_src_28000 + FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('day', ds) ) subq_5 diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time_week__plan0.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time_week__plan0.sql index 43a97950c9..b1f33eb2a6 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time_week__plan0.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time_week__plan0.sql @@ -34,18 +34,18 @@ FROM ( FROM ( -- Time Spine SELECT - DATE_TRUNC('day', time_spine_src_28000.ds) AS ds__day - , DATE_TRUNC('week', time_spine_src_28000.ds) AS ds__week - , DATE_TRUNC('month', time_spine_src_28000.ds) AS ds__month - , DATE_TRUNC('quarter', time_spine_src_28000.ds) AS ds__quarter - , DATE_TRUNC('year', time_spine_src_28000.ds) AS ds__year - , EXTRACT(year FROM time_spine_src_28000.ds) AS ds__extract_year - , EXTRACT(quarter FROM time_spine_src_28000.ds) AS ds__extract_quarter - , EXTRACT(month FROM time_spine_src_28000.ds) AS ds__extract_month - , EXTRACT(day FROM time_spine_src_28000.ds) AS ds__extract_day - , EXTRACT(DAY_OF_WEEK FROM time_spine_src_28000.ds) AS ds__extract_dow - , EXTRACT(doy FROM time_spine_src_28000.ds) AS ds__extract_doy - FROM ***************************.mf_time_spine time_spine_src_28000 + DATE_TRUNC('day', time_spine_src_28006.ds) AS ds__day + , DATE_TRUNC('week', time_spine_src_28006.ds) AS ds__week + , DATE_TRUNC('month', time_spine_src_28006.ds) AS ds__month + , DATE_TRUNC('quarter', time_spine_src_28006.ds) AS ds__quarter + , DATE_TRUNC('year', time_spine_src_28006.ds) AS ds__year + , EXTRACT(year FROM time_spine_src_28006.ds) AS ds__extract_year + , EXTRACT(quarter FROM time_spine_src_28006.ds) AS ds__extract_quarter + , EXTRACT(month FROM time_spine_src_28006.ds) AS ds__extract_month + , EXTRACT(day FROM time_spine_src_28006.ds) AS ds__extract_day + , EXTRACT(DAY_OF_WEEK FROM time_spine_src_28006.ds) AS ds__extract_dow + , EXTRACT(doy FROM time_spine_src_28006.ds) AS ds__extract_doy + FROM ***************************.mf_time_spine time_spine_src_28006 ) subq_0 ) subq_1 GROUP BY diff --git a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time_week__plan0_optimized.sql b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time_week__plan0_optimized.sql index a5d07eba96..4ceb83d067 100644 --- a/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time_week__plan0_optimized.sql +++ b/tests_metricflow/snapshots/test_query_rendering.py/SqlQueryPlan/Trino/test_min_max_metric_time_week__plan0_optimized.sql @@ -8,7 +8,7 @@ FROM ( -- Pass Only Elements: ['metric_time__week',] SELECT DATE_TRUNC('week', ds) AS metric_time__week - FROM ***************************.mf_time_spine time_spine_src_28000 + FROM ***************************.mf_time_spine time_spine_src_28006 GROUP BY DATE_TRUNC('week', ds) ) subq_5