早睡早起,方能养生
Sleep early rise early, way to keep healthy

Mysql全文搜索MATCH AGAINST

super
2023-10-09 09:54
views 448

field1,field2字段类型为text,建立FULLTEXT索引

 

 

基础用法:

 

SELECT * FROM `article` WHERE MATCH(字段) AGAINST('搜索内容') LIMIT 1

 

SELECT * FROM `article` WHERE MATCH(field1,field2) AGAINST('123123') LIMIT 1

 



分享
0 条讨论
top