--Top 10 网点
SELECT
t.site_id
FROM
(
SELECT
site_id,
count(1),
@curRank :=@curRank + 1 rank
FROM
express_order_stor t,
(SELECT @curRank := 0) f
WHERE
t.postman_id = 1877665
AND t.create_time >= '2019-02-01'
AND t.create_time < '2019-03-01'
AND t.`status` = 7
GROUP BY
t.site_id
ORDER BY
count(1) DESC
) t
WHERE
t.rank <= 10;