SQL |
SELECT DISTINCT subtyp1, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CAMP AND HIKE' and typ='HEALTH AND SAFETY' and upper(subtyp1)<>'EMPTY' and style_id IN (76,78,79,80,93,101,105,107,108,111,121,449,3798,3831,3924,3925,4089,4158,4185,14419,15650,16914,17112,17833,18270,19187,19240,19467,19618,19619,19984,20647,20648)
GROUP BY subtyp1 |