Report on Initial Contract Commitments
Inspect the result, its parameters and the SQL behind it.
- Source
- FOCUS use-case library
- Data
- FOCUS 1.0 sample
- Status
- Not in v1.0 sample
- Mode
- Read-only
- Library snapshot (UTC)
- 2026-10-08
Loading sample results
Inspect the result, its parameters and the SQL behind it.
ContractApplied and its ContractCommitmentID / ContractCommitmentAppliedCost elements are absent from the v1.0 sample, so contract-commitment purchases cannot be reported.
SELECT MIN(CU.ChargePeriodStart) AS ChargePeriodStart, MAX(CU.ChargePeriodEnd) AS ChargePeriodEnd, CU.ServiceProviderName, JSON_VALUE(CA, '$.ContractCommitmentID') AS ContractCommitmentId, SUM(CAST(JSON_VALUE(CA, '$.ContractCommitmentAppliedCost') AS FLOAT64)) AS ContractCommitmentAppliedCost FROM focus_data_table CU CROSS JOIN UNNEST(JSON_EXTRACT_ARRAY(CU.ContractApplied, '$.Elements')) AS CA WHERE JSON_VALUE(CA, '$.ContractCommitmentAppliedCost') IS NOT NULL AND ChargePeriodStart >= ? AND ChargePeriodEnd < ? AND ChargeCategory = 'Purchase' GROUP BY CU.ServiceProviderName, JSON_VALUE(CA, '$.ContractCommitmentID')