SQL |
SELECT DISTINCT subtyp2, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CAMP AND HIKE' and typ='HYDRATION' and subtyp1='Bottles' and upper(subtyp2)<>'EMPTY' and style_id IN (963,1009,1010,1011,1013,1017,1022,1025,1031,1033,1035,1042,1487,3028,3029,3034,3763,15012,17054,17669,17704,20106,20829,20830,20910,21715,21720)
GROUP BY subtyp2 |