LOCATE ( 'substr', str, pos) method
The LOCATE the SELECT ( ' XBAR ' , `foobar`); ### returns 0 the SELECT the LOCATE ( ' bar ' ,` foobarbar`); ### returns. 4 the SELECT the LOCATE ( ' bar ' , `foobarbar`, . 5 ); ## # 7 return
SELECT `column` FROM `table` WHERE LOCATE('keyword', `field`)>0
源文:https://www.cnblogs.com/mqxs/p/9703000.html