MYSQL search for right words | fixing spelling errors

后端 未结 3 710
暖寄归人
暖寄归人 2020-12-06 08:54

I have a table dictionary which contains a list of words Like:

   ID|word
   ---------
    1|hello
    2|google
    3|similar
    ...

3条回答
  •  无人及你
    2020-12-06 09:12

    you can use soundex() function for comparing phonetically

    your query should be something like:

    select * from table where soundex(word) like soundex('helo');
    

    and this will return you the hello row

提交回复
热议问题