我使用以下mysql查询对refererSource进行分组。
SELECT referrersource,count(referrersource) as counts
FROM request_events
where referrersource!=''
AND landingpage_collectionid=1
group by referrersource
在这里,我想按结果集的升序排序。如何更改上面的查询。请给出建议
最佳答案
SELECT referrersource,count(referrersource) as counts
FROM request_events
where referrersource!=''
AND landingpage_collectionid=1
group by referrersource
ORDER BY 2