list itemrequest_at as Day,
round(sum(case when t.status like 'cancelled_by_%' then 1 else 0 end)/count(*),2) as 'Cancellation Rate'
from trips t
where request_at between '2013-10-01' and '2013-10-03'
and EXISTS (select '1' from users
where users_id =t.client_id
and banned ='No'
group by request_at
EXISTS seems twice faster than JOIN. my solution with JOIN took 229 ms. Voted for your one
SELECT Request_at as Day, ROUND (SUM(CASE
WHEN Status like "%cancelled%" THEN 1
END) / count(client_id),2 ) as "Cancellation_Rate"
where request_at between date('2013-10-01') and date ('2013-10-03')
and client_id in (select users_id from Users where role="client" and banned="No")
group by Request_at;