I\'m doing some search, where users are choosing in dropdown some clauses. When they leave some box empty, I want query to ignore clause. I know CASE, and best I thought of
Try this:
WHERE a.Country = (CASE WHEN @Country > 0 THEN @Country ELSE a.Country END)