MySQL matching unicode characters with ascii version

后端 未结 5 1619
盖世英雄少女心
盖世英雄少女心 2020-12-03 14:59

I\'m running MySQL 5.1.50 and have a table that looks like this:

organizations | CREATE TABLE `organizations` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `na         


        
5条回答
  •  有刺的猬
    2020-12-03 15:59

    one thing you can do with your query string is to decode it...

    < ?php
    $query="उनकी"; // some Unicode characters
    $query=urldecode($query);
    $qry= "SELECT * FROM table WHERE books LIKE '%$query%'";
    
    //rest of the code....
    ?>
    

    it worked for me. :)

提交回复
热议问题