Using freetexttable with AND and OR

I have a lot of users asking me to build simple search forms at work so that users can more easily find reports based on various categories. Lately, a lot of them have been asking for keyword searches, and I’ve been struggling with a good way to implement this.

Recently I found the SQL Server function called FREETEXTTABLE that allows a pretty decent keyword search, and even allows you to search multiple columns in a table. The only hitch I can find is that it doesn’t recognize things like AND and OR. There’s another function called CONTAINSTABLE that supposedly does, but I’m having trouble building a query that works using that.

Has anyone used either of these for keyword searches, and if so, what works best?

Hi,

FREETEXTTABLE() Function is the part of Rowset() function. This function is the system function. The Freetexttable() Function to search a full text catalog. We will use this function server-generate rank to order my result.

Freetexttable() Function is return a table of zero, one and more rows for those columns containing character-based data type for values that match the meaning, but not the exact wording, of the text in the specified freetext_string.
You can get more help https://technet.microsoft.com/en-us/library/aa172823(v=sql.80).aspx

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.