SQL |
SELECT DISTINCT subtyp1, count(distinct style_id) as itemCount
FROM web_all_products
WHERE dept='CYCLING' and typ='COMPONENTS' and upper(subtyp1)<>'EMPTY' and style_id IN (1104,2816,6423,6455,6478,6482,6763,6811,6827,6853,6904,7078,7236,7372,7438,7467,7641,7690,7743,7751,7773,7784,7878,7883,8590,8600,8610,8683,8703,8717,10379,10380,10536,10692,10694,10940,11258,14188,14680,14773,14922,14945,14974,15062,15145,15154,15209,15346,15468,15495,15500,15588,15646,15772,15854,15941,15948,15949,15957,16104,16110,16182,16255,16293,16402,16736,17055,17241,17242,17266,17345,17367,17569,17586,17753,17823,17836,17993,18072,18094,18159,18266,18292,18696,19649,19654,19713,19790,19980,20142,20237,20662,20712,20716,20727,20744,20789,20851,10547,17582)
GROUP BY subtyp1 |