You have a stored procedure that you allow the user to enter a NULL value for. You want to be able to pass the NULL value, and the user input to the same query script.
Resolution
/*In the WHERE clause, set your criteria*/
/*You transform the NULL parameter to the value -1*/
/*Then you make it equal to -1 so as to not pass it to the proc*/
/*Or, if a value was entered, search for it in your database.*/
WHERE ((ISNULL(@YourParam, -1) = -1) or (MyTable.Value01 = @YourParam))
Back.