Want to increase your earning potential in 2018? Pad your resume with app building experience. Learn how with this hands-on course.
DECLARE @FORMSOF as varchar(1000) DECLARE @Phrase as varchar(1000) SET @FORMSOF = 'FORMSOF (INFLECTIONAL, "' + @SearchText + '")' SET @PHRASE = '"' + @SearchText + '"'; WITH Products AS ( SELECT ID, [Name], Sku, Origin, Price, ROW_NUMBER() over (ORDER BY ID) AS 'RowNumber' FROM mytable P WHERE P.Active = 1 and ( CONTAINS(Name, @FORMSOF) --Search for forms of input text in product name OR CONTAINS(Detail, @FORMSOF) -- Search for forms of input text in product description OR CONTAINS(Origin, @PHRASE) -- Search for input text in Origin field OR SKU Like '%' + @SearchText + '%' -- Search for input text in Sku field ) ) SELECT * FROM Products
Join the community of 500,000 technology professionals and ask your questions.