SQL |
SELECT DISTINCT subtyp2, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CAMP AND HIKE' and typ='SLEEP GEAR' and subtyp1='Sleeping Bags' and upper(subtyp2)<>'EMPTY' and style_id IN (544,580,581,4733,4734,4736,4739,4740,4741,4743,4744,4752,4753,4771,8364,8368,11352,11354,14003,14376,14548,14550,14586,14790,14860,15040,15311,15477,16722,17071,17072,19096,19097,19098,19099,19100,19101)
GROUP BY subtyp2 |