表字段:id,content(text类型),content字段已添加fulltext索引,10万条数据,内容是用navicat生成的随机文本。
查询SQL如下:
select * from tb_text_100w where content like "%simply double-click it in the pane%";
select * from tb_text_100w as a where match(a.content) against('"simply double-click it in the pane"');
第一条SQL:耗时13秒
第二条SQL:耗时189秒
我搞不懂为啥差距这么大,那fulltext索引的意义在哪里?
补充1:SQL执行计划
补充2:
会不会是机器配置有点问题,在本地测试了一下,感觉速度提升还是非常多的。