I was trying to write a statement which uses the WHERE LIKE \'%text%\' clause, but I am not receiving results when I try to use a parameter for the text. For example, this
It should be:
... WHERE LastName LIKE '%' + @LastName + '%';
Instead of:
... WHERE LastName LIKE '%@LastName%'