SQL |
SELECT DISTINCT subtyp2, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CYCLING' and typ='ACCESSORIES' and subtyp1='Gloves' and upper(subtyp2)<>'EMPTY' and style_id IN (5801,5802,5805,5806,5888,5890,5909,5915,5916,10723,10731,13894,14685,14687,15234,15702,15778,16396,18058,18256,19175,19235,20135,21459,21460,21461)
GROUP BY subtyp2 |