我的表在searchtxt字段中包含文本“johan smith先生”,即使用户输入任何一个输入,我也想搜索该文本: - “mrjohan”或“mr smith”或“mr johan“或”MR.johan“,”Nomatch word johan“等。但是,查尔斯先生应该选择johan smith先生的记录。我如何搜索该记录以匹配上述模式。选择与模式匹配的记录
到目前为止,我已经尝试过与此查询: -
select t.* from temp_textsearch t
where t.searchtxt like '%UserInput%'
但是不能成功,REGEXP任何想法做呢?
非常感谢... :)
,你会好起来的与匹配“史密斯先生”或“先生约翰”之前输入或'先生。约翰'但不是你建议的其他人?我认为分隔关键字的空间很重要。 – BumbleB2na
Word可以是任何记录。 – Bajrang