What is the use of MySQL SOUNDS LIKE operator?

MySQLMySQLi Database

As the name suggests, MySQL SOUNDS LIKE operator will search the similar sound values from a table. Its syntax is ‘Expression1 SOUNDS LIKE Expression2’ where, both Expression1 and Expression2 will be compared based on their English pronunciation of sound.

Example

Following is an example from ‘student_info’ table which will match the two expressions based on the pronunciation of sound:

mysql> Select * from student_info where name sounds like 'grov';
+------+--------+---------+------------+
| id   | Name   | Address | Subject    |
+------+--------+---------+------------+
| 105  | Gaurav | Jaipur  | Literature |
+------+--------+---------+------------+
1 row in set (0.00 sec)

mysql> Select * from student_info where name sounds like 'rmn';
+------+-------+---------+-----------+
| id   | Name  | Address | Subject   |
+------+-------+---------+-----------+
| 125  | Raman | Shimla  | Computers |
+------+-------+---------+-----------+
1 row in set (0.00 sec)
raja
Published on 21-Feb-2018 16:10:34
Advertisements