3 ms·
I learned about this when digging through the PHP documentation. They have the function built-in https://www.php.net/manual/en/function.soundex.php https://www.
by francislavoie 7y ago
I learned about this when digging through the PHP documentation. They have the function built-in https://www.php.net/manual/en/function.soundex.php https://www.php.net/manual/en/function.soundex.php
In a similar vein, Levenshtein distance is also built-in which is very useful for fuzzy searching https://www.php.net/manual/en/function.levenshtein.php https://www.php.net/manual/en/function.levenshtein.php
- ehnto 7y agoI once built a search engine for web agencies that you could search through by the technologies they worked with. All I did to make it fast was index all the data for a company into a few blobs and then fuzzy search the text blobs with Lucene, which used Levenshtein distances under the hood. It was lightening fast, stupid simple and all hosted on the same VM.
- teddyh 7y agoPostgreSQL also comes with a “fuzzymatch” module, which includes both Soundex and Levenshtein functions, and also Metaphone and Double Metaphone: https://www.postgresql.org/docs/current/fuzzystrmatch.html https://www.postgresql.org/docs/current/fuzzystrmatch.html