用错字输入全文搜索sql server [英] full text search sql server with mistyped words

查看:91
本文介绍了用错字输入全文搜索sql server的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们正在评估一系列模糊搜索的选项。
我们的要求之一是错误的单词匹配。 CRA1G的OCR(编号为1)必须匹配'CRAIG'。



在sql server中进行全文搜索似乎已经接近,但没有雪茄。



除了'FORMSOF(Inflectional,CRA1G)'之外,还有一些选项可以替代这些类型的不匹配,并且仍然可以得到结果吗?

我无法找到类似SOUNDEX的东西,绝对不够好。



接下来我可以尝试使用Lucene,它具有很好的模糊搜索能力。 p>

问候

克雷格。

解决方案

SQL Server 2008支持应用程序应该让你到你需要的地方。你会将你的拼写错误定义为同义词。请参阅 http://msdn.microsoft.com/zh-cn/library/ms142491。 ASPX

编辑:
根据我的理解,您无法使用通配符或正则表达式方法来执行此操作。您必须为您的单词定义常用替换集模式,而且您预计这些模式最常出现错误类型。

We are evaluating a bunch of options at the moment for Fuzzy searches. One of our requirements is that mistyped words be matched. An OCR of CRA1G (with the number 1) must match 'CRAIG'.

Full text search in sql server seems to get close, but no cigar.

Are there some options besides 'FORMSOF(Inflectional, CRA1G)' that might be able to make substitutions for these types of mismatches and still get results?

I am unable to find anything similar SOUNDEX is definitely not good enough.

I might try Lucene next, which has good fuzzy search capability.

Regards

Craig.

解决方案

SQL Server 2008 supports thesauruses should get you to where you need. You would define your misspellings as synonyms. See http://msdn.microsoft.com/en-us/library/ms142491.aspx.

Edit: To my understanding, you couldn't do this using a wildcard or regular expression approach. You'd have to define common replacement set patterns for your words that you anticipate will be most commonly mis-typed.

这篇关于用错字输入全文搜索sql server的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆