SQL |
SELECT DISTINCT subtyp2, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CYCLING' and typ='ACCESSORIES' and subtyp1='Computers' and upper(subtyp2)<>'EMPTY' and style_id IN (2735,6417,6438,7051,7094,7786,7854,8736,8739,10144,10263,10430,10503,10504,10627,10634,10956,11419,14135,16291,16310,17083,17636,17777,19246,19372,20772,20835,20907,7377)
GROUP BY subtyp2 |