简体   繁体   English

我可以在SOUNDEX()函数中传递多个参数以获得多值结果吗

[英]can i pass more than one parameter within SOUNDEX() function to get multiple value result

My student table stu_table contains many different student name but most of them sound similar, in the field stu_name . 我的学生表stu_table包含许多不同的学生的名字,但他们大多听起来很相似,在野外stu_name

For example: 例如:

Mrinmoy, Minmay, Mrinmay, Minmoy, 
Tanmoy ,Tanmay, Tonmoy, Tanmy, 
Rajesh, Rajes, 
Anirban, Anirbon.
  • Here first 5 make a similar sound group of name 在这里,前5个名字类似的声音组
  • Next 3 make a similar sound group of name 接下来的3个类似的声音组名称
  • and last 2 make another group of similar sound name. 最后2个则组成另一组相似的声音名称。

Can i pass more than one parameter (for example Mrinmoy and Tanmoy) within a single SOUNDEX() function to fetch both result. 我可以在单个SOUNDEX()函数中传递多个参数(例如Mrinmoy和Tanmoy)来获取两个结果。

If yes then how to pass it. 如果是,那么如何通过。 Please help. 请帮忙。

soundex() accept only one parameter. soundex()仅接受一个参数。 So you have to use OR in sql. 因此,您必须在sql中使用OR。 You can try this sql. 您可以尝试此sql。

SELECT * FROM `stu_table` where soundex(`stu_name`)= soundex('Anirban') OR soundex(`stu_name`)=soundex('Tonmoy')

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM