JJS*_*JJS 5 sql-server full-text-search
有没有办法使用全文查询组件来生成全文字典中作为单词屈折形式的单词列表?
此查询将根据查询为我提供匹配项。
select *
from keywords
WHERE CONTAINS(keyword, 'FORMSOF(INFLECTIONAL, migrate)')
Run Code Online (Sandbox Code Playgroud)
我对它用作匹配的单词感兴趣。我想要一个像
migrate
migrates
migration
migrations
Run Code Online (Sandbox Code Playgroud)
本质上是这个词的屈折/共轭形式。
您可以找到将在与SQL Server 中的sys.dm_fts_parser函数匹配时使用的单词。
语法
sys.dm_fts_parser('query_string', lcid, stoplist_id, accent_sensitivity)
Run Code Online (Sandbox Code Playgroud)
我不会详细介绍参数值,但“ lcid ”很重要。在下面的示例中,我使用 1033 表示英语 - 美国。我已经尝试过 1036,法语 - 标准,但可以肯定的是,除了单词本身之外,我没有得到任何结果,因为法语词典中不存在该单词。
例子
SELECT display_term
FROM SYS.DM_FTS_PARSER('FORMSOF(INFLECTIONAL, welcome)', 1033, 0, 0)
Run Code Online (Sandbox Code Playgroud)
结果
welcome's
welcomed
welcomes
welcomes'
welcoming
welcome
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
2942 次 |
最近记录: |