SQL |
SELECT DISTINCT subtyp2, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CLOTHING AND FOOTWEAR' and typ='WOMENS' and subtyp1='By Activity' and upper(subtyp2)<>'EMPTY' and style_id IN (419,439,442,1308,1318,1319,1341,1342,1368,1429,1430,1758,2148,2156,5900,5920,6295,10720,11280,11402,14177,14635,14683,15251,16405,16406,16408,16618,16803,16805,17671,18713,18714,20904,20905,20906,20962,20963,20964,20965,20966,20967,20968,20969,21715)
GROUP BY subtyp2 |