SQL |
SELECT DISTINCT subtyp2, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CAMP AND HIKE' and typ='HEALTH AND SAFETY' and subtyp1='Camp Bathroom' and upper(subtyp2)<>'EMPTY' and style_id IN (445,448,453,2040,3784,3869,3921,3922,4039,4055,4111,4132,4203,4742,8392,8399,8450,8451,13975,13976,15650,16914,17136,17404,17406,17407,17562,17832,17833)
GROUP BY subtyp2 |