1

Let's say I want to search for a list containing 'PS3':

SELECT * FROM [TABLE] WHERE CONTAINS(Title, 'PS3')

When the Title is proceeded by an underscore it will not return it.

  1. Oblivion-PS3 -> Good
  2. Oblivion PS3 -> Good
  3. Oblivion_PS3 -> Not returning

I suppose the underscore is not a break word.

How can I fix it so that the underscore can be used as a break word?

  • Do you want to implement custom work breaker ? This will help you blogs.msdn.com/b/shajan/archive/2005/12/09/… – Kin Shah Sep 23 '13 at 21:07
  • I found it! :) I changed the Language for Word Breaker in the Full-Text Catalog to Traditional Chinese. I used the sys.dm_fts_parser in order to find what language could use the underscore as a break word. 1033 - English 1028 - Traditional Chinese select * from sys.dm_fts_parser('Oblivion_PS3', 1028, 5, 0) return Oblivion AND PS3 select * from sys.dm_fts_parser('Oblivion_PS3', 1033, 5, 0) return Oblivion_PS3 – user2258152 Sep 23 '13 at 21:14
  • 1
    Please post it as answer, so others can benefit. Good work ! – Kin Shah Sep 23 '13 at 22:05
0

I found it! :)

I changed the Language for Word Breaker in the Full-Text Catalog to Traditional Chinese.

I used the sys.dm_fts_parser in order to find what language could use the underscore as a break word.

1033 - English

1028 - Traditional Chinese

select * from sys.dm_fts_parser('Oblivion_PS3', 1028, 5, 0)

return Oblivion AND PS3

select * from sys.dm_fts_parser('Oblivion_PS3', 1033, 5, 0)

return Oblivion_PS3

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.