Query editor
SELECT substr(outcome, 3) AS outcome, min(substr(outcome, 1, 1)) AS sort_key,count(*) AS routes, count(DISTINCT oapp) AS apps,sum(lost_usd_30d_before) AS canary_usd_30d_before_removal,count_if(canary_msgs_30d_before > 0) AS routes_with_canary_traffic_beforeFROM query_8958350GROUP BY 1 ORDER BY 2