如何执行多关键字搜索 [英] how to perform multi keyword search

查看:90
本文介绍了如何执行多关键字搜索的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嗨...
我试图执行搜索操作...
但我想知道如何从多个关键字中搜索特定名称...
有可能吗?

hi...
i have tried to perform the search operation...
but i want to know how to search a particular name from multiple keywords...
is it possible?
can u give me an suggestion to do this operation.?

推荐答案

创建一个包含搜索词的临时表,然后对表/列进行联接( s)您正在搜索.
Create a temporary table that contains the search words, and then do a join on the table/column(s) you''re searching.


您始终可以在查询级别进行此搜索.
只需使用IN子句在Where中搜索名称.

select * from table where name in (name1,name2)
You could always do this search at the query level.
Just search for a the names within the Where using an IN clause.

select * from table where name in (name1,name2)




您也可以使用
进行搜索


you can also search using,

select * from tablename where columnname in (%value1%,%value2%,....);



谢谢
-amit.



thanks
-amit.


这篇关于如何执行多关键字搜索的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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