这样可以很清楚我有这个字段使用通配符SQL中的文本字段搜索词
Columntobesearch
aword1 bword1
aword2 bword2
aword3 bword4
现在我想要做的就是使用SQL通配符所以我做了什么搜索这样
%searchbox%
我放置通配符在我的搜索,但它会搜索什么样的两端就是在球场上时,我搜索“AWORD”的所有字段的显示,但是当我搜索“bword”
的第一个字没有正在显示,请帮助。
这是我的全部代码
$Input=Input::all();
$makethis=Input::flash();
$soptions=Input::get('soptions');
$searchbox=Input::get('searchbox');
$items = Gamefarm::where('roost_hen', '=',Input::get('sex'))
->where($soptions, 'LIKE','%' . $searchbox . '%')
->paginate(12);
您可以分享代码,您如何进行查询? – 2015-02-11 03:50:02
我编辑了我的问题先生 – 2015-02-11 14:23:12