Chart controls and notes
Showing the first 20 categories. Open full screen to explore all 37 categories.
Inspect the result, its parameters and the SQL behind it.
Showing the first 20 categories. Open full screen to explore all 37 categories.
37 rows. Scroll inside the table to see more.
select provider_name as provider_name,
service_name as service_name,
sum(contracted_cost) as total_contracted_cost,
sum(effective_cost) as total_effective_cost,
(sum(contracted_cost) - sum(effective_cost)) / nullif(sum(contracted_cost), 0) as effective_discount_ratio
from focus.cost_and_usage
where charge_period_start >= $1::timestamptz
and charge_period_end < $2::timestamptz
group by provider_name, service_name
having abs(sum(contracted_cost)) >= 0.01
order by total_contracted_cost desc nulls last, provider_name, service_name
limit 500SELECT ProviderName, ServiceName, SUM(ContractedCost) AS TotalContractedCost, SUM(EffectiveCost) AS TotalEffectiveCost, (SUM(ContractedCost) - SUM(EffectiveCost)) / NULLIF(SUM(ContractedCost), 0) AS EffectiveSavingsRate FROM focus_data_table WHERE ChargePeriodStart >= ? AND ChargePeriodEnd < ? GROUP BY ProviderName, ServiceName