I had queries that used match against email which started failing when I switched to innodb since @ is used to search for words a certain distance apart in InnoDB:SELECT username FROM users WHERE MATCH(user_email) AGAINST('[email protected]' IN BOOLEAN MODE);ERROR 1064 (42000): syntax error, unexpected '@', expecting $endSELECT username FROM users WHERE MATCH(user_email) AGAINST("[email protected]" IN BOOLEAN MODE);ERROR 1064 (42000): syntax error, unexpected '@', expecting $endmysql>尝试像这样包装您的电子邮件地址:Try wrapping your email address like this:SELECT username FROM users WHERE MATCH(user_email) AGAINST('"[email protected]"' IN BOOLEAN MODE);或逃脱:SELECT username FROM users WHERE MATCH(user_email) AGAINST('\"[email protected]\"' IN BOOLEAN MODE); 这篇关于MySQL InnoDB全文搜索,包含电子邮件地址的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 09-26 08:57