I have a query that take 2 parameters. parameter 1 is mandatory, parameter 2 is optional.
I would like the query to execute that when the 2nd parameter is NULL it is disregarded and only the 1st parameter from the WHERE clause is used.
SELECT Column1, Column2 FROM Table1 WHERE
Column3 = @Param1 AND ...