SQL |
SELECT DISTINCT subtyp2, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CLOTHING AND FOOTWEAR' and typ='WOMENS' and subtyp1='Tops' and upper(subtyp2)<>'EMPTY' and style_id IN (5326,5745,5771,11311,14069,16870,17895,18261,18712,18965,19038,19297,20875,20958,21114,21117,21121,21124,21126,21133,21134,21136,21140,21259,21315,21355)
GROUP BY subtyp2 |