SELECT subtyp_2, web_url
FROM tb_web_taxonomy
WHERE dept='CLOTHING AND FOOTWEAR' and typ='WOMEN''S' and subtyp_1='BOTTOMS' and subtyp_2>'' and subtyp_3='EMPTY' and subtyp_2<>'EMPTY'
ORDER BY sort_position
query
RESULTSET
query
ITEMCOUNT
SUBTYP2
1
3
ACTIVE PANTS
2
6
CAPRIS
3
13
CASUAL PANTS
4
7
SHORTS
CACHED
false
EXECUTIONTIME
17
SQL
SELECT DISTINCT subtyp2, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CLOTHING AND FOOTWEAR' and typ='WOMENS' and subtyp1='Bottoms' and upper(subtyp2)<>'EMPTY' and style_id IN (5565,5649,16401,16442,16683,19167,19557,19584,20871,20876,20960,21115,21116,21128,21132,21138,21240,21319,21362,21363,21364,21576)
GROUP BY subtyp2