SQL |
SELECT DISTINCT subtyp1, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CLOTHING AND FOOTWEAR' and typ='MENS' and upper(subtyp1)<>'EMPTY' and style_id IN (12,1754,1827,1831,1859,1890,1905,1907,1944,2222,2223,2232,2235,3104,3529,3549,3641,4846,4847,4854,5221,5249,5298,5346,5360,5362,5364,5454,5550,5551,5552,5644,5645,5653,5731,5752,5753,5763,5876,5882,8011,8075,9045,9060,9149,9377,11318,11319,11321,14281,14282,14283,14287,14489,14734,14738,15196,15539,15638,15643,15743,15746,15747,15749,15844,15914,16122,16248,16655,16671,16675,16676,16685,16787,16802,16845,16846,16959,17170,17174,17194,17199,17218,17349,17592,17806,18286,18954,18955,19157,19184,19253,19264,19266,19267,19412,19875,19879,20134,20267,20268,20695,20881,20883,20980,21069,21247,21250,21252,21254,21255,21267,21371,21374,21382,21383,21386,21388,21391,21634,21647,1615)
GROUP BY subtyp1 |