Select top 50 (a.yuefen, a.seller_name) from
(select concat(‘2019M’, month(dt)) as ‘yuefen’, seller_name, sum(gmv) as total
From purchase
Where month(dt) = 5
Group by seller_name order by total desc) as a
Union all
Select top 50 (b.yuefen, b.seller_name) from
(select concat(‘2019M’, month(dt)) as ‘yuefen’, seller_name, sum(gmv) as total
From purchase
Where month(dt) = 6