Addressed comments

This commit is contained in:
Joaquin Ossa 2025-01-30 16:30:03 +01:00
parent bb9dea8ed6
commit 40c8e20e70
2 changed files with 7 additions and 12 deletions

View file

@ -72,14 +72,6 @@ where
)
and {{ is_date_before_previous_month("date") }}
)
-- Not show current month if the metric is Expected MRR, unlike other
-- revenue metrics, Expected MRR is calculated for the next month, so it is not
-- affected by the invoicing cycle.
or not
(
lower(metric) like '%mrr%'
and date_trunc('month', date)::date = date_trunc('month', now())::date
)
-- Keep all history for the rest of metrics
or not
(
@ -91,5 +83,8 @@ where
or lower(metric) like '%damage host%'
)
)
-- If metric is Churn Rate, do not show month in progress
and not (lower(metric) like '%churn rate%' and is_current_month = true)
-- If metric is Churn Rate or Expected MRR, do not show month in progress
and not (
(lower(metric) like '%churn rate%' or lower(metric) like '%mrr%')
and is_current_month = true
)