SQL |
SELECT DISTINCT subtyp1, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CAMP AND HIKE' and typ='SLEEP GEAR' and upper(subtyp1)<>'EMPTY' and style_id IN (544,558,561,563,564,566,567,580,581,583,589,609,613,1441,1447,1465,1466,1481,1498,1499,1507,1524,1537,4064,4718,4719,4733,4734,4736,4739,4740,4741,4743,4744,4760,4761,4762,4764,4765,4766,4767,4768,4770,4771,8351,8353,8368,8382,8409,8423,8448,9686,11237,11238,11282,11283,11284,11285,11286,11287,11351,11354,14003,14376,14415,14548,14550,14552,14591,14790,14860,14861,14967,14968,15040,15311,15477,15478,15479,16102,16175,16177,16708,16710,16711,16714,16715,16722,17070,17071,17072,17134,17135,17138,11352)
GROUP BY subtyp1 |