[thelist] Phone Number Word Permutation Algorithm

Fred Jones fredthejonester at gmail.com
Tue Dec 2 11:55:23 CST 2008

> Sorry, I completely missed the boat on the solution. Here's what you
> should look into. Convert each word in your English database to its
> number pad equivalent. Then perform the number search on that column.

I thought about that, but if I use my suggested approach, then the
varchar comparison is a simple equality comparison and I am uncertain
if doing a string equality will be significantly faster than a
numerical one.

You also got me thinking, however. Perhaps I could index the words
very simply by adding an index for the first letter. Then I would need
only to search that subset, based on the first letter of my string. I
could always do this to two levels, but I think one would help and
would be easy to manage.


More information about the thelist mailing list