SQL |
SELECT DISTINCT subtyp2, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CAMP AND HIKE' and typ='HEALTH AND SAFETY' and subtyp1='Sun & Bug Protection' and upper(subtyp2)<>'EMPTY' and style_id IN (75,76,92,93,99,100,105,107,108,119,121,443,3772,3798,3816,3877,4089,4185,8421,8422,8424,9215,11337,15859,15926,15927,16311,17320)
GROUP BY subtyp2 |