sum(case when platform_type = 'Amazon' then bailun_sku_quantity_ordered - bailun_sku_quantity_pushed else 0 end) as amazon_quantity,
sum(case when platform_type not in ( 'Amazon','Aliexpress') then bailun_sku_quantity_ordered - bailun_sku_quantity_pushed else 0 end) as other_quantity
FROM
dc_base_oms_sku
dc_base_oms_sku_30
WHERE
bailun_order_status = 'Handling'
and bailun_interception_status in('None','Failed')