• HanShi (9/5/2013)


    You need to change the HAVING clause to get your desired results. With the code below you can check if both 'Walker' and 'Cane' exists at least once.

    HAVING sum(case when NameTools = N'walker' then 1 else 0 end) > 0

    AND sum(case when NameTools = N'Cane' then 1 else 0 end) > 0

    Thank you so much master:w00t: