Name

SOUNDEX( )

Synopsis

SOUNDEX(string)

This function returns an alphanumeric equivalent of a string based on an algorithm.

SELECT IF(SOUNDEX('him') = SOUNDEX('hymm'),
'Sounds Alike', 'Does not sound alike')
AS 'Sound Comparison';
+------------------+
| Sound Comparison |
+------------------+
| Sounds Alike     |
+------------------+

SOUNDEX( ) was designed to allow comparisons between fuzzy input, but it’s rarely used.

Get MySQL in a Nutshell now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.