开发者

MySQL Collate Latin1_General_CI_AI Problem

开发者 https://www.devze.com 2023-02-18 21:45 出处:网络
I h开发者_Python百科ave the following select statement where I\'m trying to search for a players first and last name that may contain accents in it.

I h开发者_Python百科ave the following select statement where I'm trying to search for a players first and last name that may contain accents in it.

$sql = "
    SELECT * FROM player
    WHERE player.player_first LIKE '%$first%'
    AND player.player_last LIKE '%$last%'
    ";

I adding COLLATE Latin1_General_CI_AI after before both of the LIKE clauses, but that didn't work and returned errors.

Any help would be appreciated.


According to MySQL doc the collation Latin1_General_CI_AI does not exists.

Try latin1_general_ci instead.

0

精彩评论

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

关注公众号