select date, round( ( sum( case when type = 'no_completed' then 1 else 0 end ) / count(type) ), 3 ) p from ( select * from e...