SELECT subtyp_1, web_url
FROM tb_web_taxonomy
WHERE dept='CYCLING' and typ='ACCESSORIES' and subtyp_1>'' and subtyp_2='EMPTY' and subtyp_1<>'EMPTY'
ORDER BY sort_position
query
RESULTSET
query
ITEMCOUNT
SUBTYP1
1
4
COOL WEATHER ACCESSORIES
2
3
GLOVES
3
3
HELMETS
CACHED
false
EXECUTIONTIME
16
SQL
SELECT DISTINCT subtyp1, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CYCLING' and typ='ACCESSORIES' and upper(subtyp1)<>'EMPTY' and style_id IN (2159,5794,5795,5805,5836,14536,14741,16396,17553,21459)
GROUP BY subtyp1