I am performing SQL prefix search in my ASP.NET application.For this purpose I have written a stored procedure in which i am writing following query:
SELECT Description, ProductDescriptionID
FROM Production.ProductDescription
WHERE CONTAINS (Description, ' "top*" ' );
I have parameter as @pvchProductName in my procedure.How can i replace top word with parameter value in above query?I am facing syntax problems with single and double quotations.
?
It is unclear, however, how much of the quotes / asterisks / whitespace you want to include in the filter condition – you may want to check that a bit.