开发者

Trouble with MySQL FULLTEXT indexes

开发者 https://www.devze.com 2023-04-05 09:12 出处:网络
I have been entering the following SQL statement, but it has not been turning up any results and I cannot figure out why. The error on phpMyAdmin reads:

I have been entering the following SQL statement, but it has not been turning up any results and I cannot figure out why. The error on phpMyAdmin reads:

#1191 - Can't find FULLTEXT index matching the column list 

This is my SQL statement:

SELECT *, MATCH(subj_name, course_name, content_type) AGAINST('math, statistics, 
test') AS sco开发者_运维技巧re from table1 WHERE MATCH(subj_name, course_name, content_type) 
AGAINST('math, statistics, test') ORDER BY score desc;

And this is how I made my index:

ALTER TABLE table1 ADD FULLTEXT(subj_name, course_name, content_type);


try to add

ALTER TABLE table1 ADD FULLTEXT fulltext_index(subj_name, course_name, content_type);
0

精彩评论

暂无评论...
验证码 换一张
取 消