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,979,981,990,991,1000,1004,1009,1010,1011,1013,1014,1017,1018,1019,1022,1025,1031,1032,1033,1034,1035,1038,1042,1043,1044,1045,1046,1449,1450,1457,1471,1487,1495,1517,1519,1547,2496,3025,3026,3027,3028,3029,3034,3042,3763,3775,3824,3830,3852,3855,3937,3944,4108,4140,5052,5053,5082,5094,5130,5132,5134,5153,5158,5161,5167,5199,5202,8205,14005,14006,14166,14235,14238,14555,14564,14565,14897,14969,15011,15012,15014,15015,15016,15017,15081,15301,15593,15783,15784,15785,15876,16114,16164,16166,16289,16585,16590,16591,16592,16593,16760,16761,16972,17047,17048,17049,17050,17051,17054,17250,17347,17476,17503,17504,17558,17587,17668,17669,17704,17721,18339,18340,18778,19002,19003,19455)
GROUP BY subtyp1 |