I have below query to perform multiple columns search:
SELECT
prod.pid,
prod.pname,
prod.description,
prod.status,
foto.set_cover,
foto.file
FROM products prod
INNER JOIN second_child_categories secd ON prod.category_id = secd.second_id
INNER JOIN photos foto ON prod.pid = foto.pid
WHERE MATCH (prod.pname, prod.description)
AGAINST ('home')
AND foto.set_cover = '1'
AND prod.status = '1'
ORDER BY prod.created_date DESC
I use InnoDB engine and MySql Ver 14.14 Distrib 5.6.35
I added fulltext index
in products
table
ALTER TABLE `products` ADD FULLTEXT (`pname`);
ALTER TABLE `products` ADD FULLTEXT (`description`);
I run the query and get error:
#1191 - Can't find FULLTEXT index matching the column list
What's wrong with the query?
Thanks in advance.