May 20, 2016 at 3:58 am
I have an application in which a user can typ in a word or words and SQL Server finds the right rows.
I've used FREETEXT because I want it to be possible that the user can type multiple words to search on (with CONTAINS I have to convert that string to 'Word1 OR Word2').
But I just found out that with FREETEXT, if I search for example for 'Projectnummer' and I type 'Project', it will not find it. I cannot use a * in FREETEXT or an % to achieve the desired result.
How can I use FREETEXT so that I'm able to find words on a partial criterium and still search for multiple words
May 25, 2016 at 1:43 pm
FREETEXT searches are all about meaning, so SQL Server looks in the thesaurus to find matching words. If you edit the thesaurus so that 'Projectnummer' is a synonym for 'Project', it will find it. If the term isn't in the thesaurus, it's not going to find it.
But if you want to use prefix terms in searches then limiting the search terms and using this form will work:
CONTAINS (Textfield, '"Project*"' )
I'm not an expert but that's my understanding.
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply