Report application cost month over month
As an application owner or engineering team I want to track the month over month costs of my application.
- Source
- FOCUS MCP snapshot
- FOCUS editions
- v1.0, v1.1, v1.2, v1.3, v1.4
- Queries
- 1
- Mode
- Read-only
- Library snapshot (UTC)
- 2026-10-08
Report application cost month over month
Adapted to v1.0- Source
- FOCUS 1.0 sample
- Result rows
- 3
- Status
- Adapted to v1.0
- Execution
- Precomputed
- Result snapshot (UTC)
- 2026-10-11
Column adaptations (1)
Application cost by service and month
3 rows. Scroll inside the table to see more.
Inspect Postgres SQL and original FOCUS SQL
Postgres SQL, as run
select to_char(date_trunc('month', billing_period_start), 'YYYY-MM') as billing_month,
service_name,
sum(effective_cost) as total_effective_cost
from focus.cost_and_usage
where tags->>'application' = $1::text
and charge_period_start >= $2::timestamptz
and charge_period_end < $3::timestamptz
group by 1, 2
order by billing_month, total_effective_cost desc nulls last, service_name
limit 500Original FOCUS SQL
SELECT MONTH(BillingPeriodStart), ServiceName, SUM(EffectiveCost) AS TotalEffectiveCost FROM focus_data_table WHERE Tags["Application"] = ? AND ChargePeriodStart >= ? AND ChargePeriodEnd < ? GROUP BY MONTH(BillingPeriodStart), ServiceName
Columns used
Column names from the source use case.