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,429,784,1753,1827,1890,1905,1907,1909,1944,1946,2136,2137,2138,2156,2223,3092,3260,3407,3529,3549,3641,3797,4847,4854,5221,5225,5249,5298,5299,5309,5313,5316,5330,5337,5550,5551,5552,5644,5645,5653,5706,5719,5722,5731,5752,5753,5851,5874,5882,5884,9069,9145,9149,9377,9400,9915,11319,11321,11362,13959,13961,14101,14281,14282,14283,14489,14678,14683,14684,15499,15635,15638,15643,15698,15744,15745,15746,15747,15912,15914,16125,16148,16670,16672,16676,16802,16827,16846,16959,17170,17199,17348,17806,18141,18774,18947,18954,19184,19253,19255,19264,19266,19267,19282,19879,19954,20054,20188,20221,20262,20335,20376,20385,20567,20878,20879,20880,20883,20902,20976,20978,20980,21020,21061,21067,21243,21250,21251,21255,21261,21371,21374,21375,21376,21377,21382,21383,21451,21570,21573,21577,21579,21583,21593,21634,1615,11356)
GROUP BY subtyp1 |