查询订单每分钟峰值
select count(1) as num,extract(hour from created_at) as the_hour,extract(minute from created_at) as the_minute from pay_records p where app_id=104 and created_at > ‘2017-01-05 00:00:00’ and created_at < ‘2017-01-06 00:00:00’ group by the_hour,the_minute order by num desc limit 10;