G
Guest
Hello,
I know that this question might need to also be in the SQL forum, but I'm
not sure where I need to code this. So here it is.
I need to create a search textbox that allows users to type in multiple
words. Like if they wanted to search for "big red house". I want to return
all records that have either "big", "red" or "house" in them. How can I do
this dynamically?
Currently I just send to the database something like this:
SELECT DISTINCT *
FROM MyTable
WHERE (Description LIKE @Search)
But that only returns where description is like all search words together.
So I'm not sure if the change I'm gonna need to make is in my c# code or in
my stored procedure.
Thanks for you help
Michael
I know that this question might need to also be in the SQL forum, but I'm
not sure where I need to code this. So here it is.
I need to create a search textbox that allows users to type in multiple
words. Like if they wanted to search for "big red house". I want to return
all records that have either "big", "red" or "house" in them. How can I do
this dynamically?
Currently I just send to the database something like this:
SELECT DISTINCT *
FROM MyTable
WHERE (Description LIKE @Search)
But that only returns where description is like all search words together.
So I'm not sure if the change I'm gonna need to make is in my c# code or in
my stored procedure.
Thanks for you help
Michael