SQL |
SELECT DISTINCT subtyp2, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CLOTHING AND FOOTWEAR' and typ='MENS' and subtyp1='Footwear' and upper(subtyp2)<>'EMPTY' and style_id IN (3346,3349,3354,4973,4993,4995,5004,11626,14648,15448,16510,16582,16725,16934,16935,16962,17612,17646,17859,18510,18655,18901,19073,19208,19612,19750,20212,21607)
GROUP BY subtyp2 |