+------------+---------+-------------+ | n | n_mfmt | n_mfmt_pct | +------------+---------+-------------+ | 656646289 | 619970 | 0.0944 | +------------+---------+-------------+ select sum(1) as n, # Testing for %mobileformat% catches # # ?action=parse...&mobileformat&... # ?action=parse...&mobileformat=...&... # # The presence of the mobileformat parameter implies the presence of action=parse. sum(if(uri_query like '%mobileformat%', 1, 0)) as n_mfmt, round(100 * sum(if(uri_query like '%mobileformat%', 1, 0)) / sum(1), 4) as n_mfmt_pct from wmf.webrequest where year = 2018 and month = 11 and day = 28 and uri_path = '/w/api.php' ;