查询
# 查询状态到200的用户
status: 200| select * order by time_local limit 100
常用统计
统计status PV数量
* | SELECT status, count(*) AS PV GROUP BY status
各网站的PV数
* | select host, count(*) as count group by host
访问量排行前100的IP
* | select remote_addr, count(*) as count group by remote_addr order by count desc limit 100
IP统计
排行前10的ip
(*)| select count(1) as pv, remote_addr as client_ip group by client_ip order by pv desc limit 10
distinct
统计独立ip数量
* | select count(distinct remote_addr) as ip
# where 统计
* | select count(distinct remote_addr) as ip where host = 'xxx.jobpi.cn' and request_uri like 'xxxx%' and request_uri not like '%getAppConfig%'
分页
#类似mysql的limit
* | select * order by time_local limit 10000,100