sqlserver全文索引 contains和freetext 的使用方法
Contains
例如,下面语句检索Book表的Title列和Notes列中包含“database”或“computer”字符串的图书名称及其注释信息:
select title, notes
from book
where contains(tilte, ‘database’) or contains(notes,‘database’)
or contains(title,‘computer’) or contains(notes,‘computer’)
freetext
例如,下面语句使用FREETEXT语句搜索Book表中包含“Successful Life”字符串的数据行:
select title, notes
from book
where freetext(*,‘Successful Life’)
浙公网安备 33010602011771号