Please suggest a fuzzy matching option I can use in T-SQL for search operations. The following is a simplification of what I'm trying to do. I have a table called Databases (name varchar, instanceID int) which lists the database name and foreign key reference to a table which holds a list of SQL Server instances. I want to perform a search which will yield a list with 100% matches, LIKE matches, and fuzzy matches in that order. While I have most of this figured out, my question is: what is the best strategy to perform a fuzzy match?
I already have the equality and LIKE matches working. Also, using SOUNDEX, I am able to glean some fuzzy matches. However, the SOUNDEX seems to only match when the first few letters are the same and also produces some false positives. Other methods I have tried are matching only on the LEFT(x) characters and using REPLACE to eliminate spaces and punctuation. I need to do this all in T-SQL. What can you suggest to me?
other tags: fuzzy-matching, search