在搜索句子时需要帮助 [英] need help in searching a sentence
本文介绍了在搜索句子时需要帮助的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
大家好
请告诉我如何编码以在C#应用程序中搜索完整的句子..
例如你叫什么名字"-我想搜索这个
因此,如果所有单词都存在,则应该返回相同的单词,否则,如果匹配的单词很少,那么它也应该返回..
我正在使用sql-server 2005和visual studio 2008
等待您的回复.
谢谢
Hi all
Please tell me how to code to search a full sentence in C# application..
e.g. "What is your name"-i want to search this
so if all words are present then it should return the same else if few words matches then that also it should return..
i m using sql-server 2005 and visual studio 2008
waiting for ur replies.
Thank you
推荐答案
写一个存储过程,并在该存储过程中编写以下3条查询
Write a stored procedure and in that stored procedure write 3 query as below
query1 = SELECT * FROM tableName WHERE cloumnName like RegExpForExactMatch;
query2 = SELECT * FROM tableName WHERE cloumnName like RegExpForAllMatch;
query3 = SELECT * FROM tableName WHERE cloumnName like RegExpForAnyMatch;
然后使用并集执行查询;
希望对您有帮助.
And then execute the query with the union;
Hope this will help you.
这篇关于在搜索句子时需要帮助的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文