SQL |
SELECT DISTINCT subtyp1, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CAMP AND HIKE' and typ='HYDRATION' and upper(subtyp1)<>'EMPTY' and style_id IN (963,975,980,981,989,990,991,993,1000,1009,1010,1011,1013,1017,1019,1022,1025,1031,1033,1035,1038,1042,1044,1046,1449,1450,1456,1457,1471,1487,1495,1517,1519,1547,2496,3025,3028,3029,3034,3763,3824,3851,3944,4108,4140,5052,5053,5082,5130,5132,5138,8205,14006,14166,14238,14564,14565,14969,15011,15012,15015,15301,15876,16114,16164,16166,16586,16591,16592,16761,16972,17049,17054,17250,17347,17476,17503,17558,17587,17669,17704,17721,18061,18339,19002,19455,20106,20829,20830,20831,20910,21705,21715,21718,21719,21720)
GROUP BY subtyp1 |