From: Mikel Lindsaar Date: 2008-05-30T18:09:24+09:00 Subject: Address search algorithms ------=_Part_13245_15987435.1212138445951 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline Heya all, Got an interesting little problem, not specifically Ruby, but I hope to solve it with some nice ruby :) I need to be able to do searches on a data set of a street address. The address has three fields, what is needed is an efficient way to search this address with partial data. The addresses are in a database, what I am thinking is going through and pre generating a search string based on the three concatenated address values and then index this search column and search off that using the output from the same algorithm on the entered search values. Would full text search be the best solution here? The DB is on postgres by the well. The problem is that someone might want to search for "back st" and expect to match "123 back street", or worse, "123 back lane" and get "123 back street" Anyone else run into these sorts of problems, any feed back? Mikel ------=_Part_13245_15987435.1212138445951--