0

i am new to android development,so dint get me wrong. I am developing an application in which a text is generated.which is normally a word. The word is checked in a database for is corresponding value pair. Here the word is the key and its corresponding value is the value . Since the text is auto generated it sometimes goes wrong(mis spelled). How do i perform a check of auto generated word to match with the mostly matched letters in the database of key word.

example: auto-generated word(key) - value americ: america : a country Here the auto generatd word is americ(key) is not matched since it only contains america in its pair set.it need to be corrected as america.

4

1 回答 1

0

您可能正在使用 SQLite。你最好的选择是soundex这里描述。

Soundex 有很多缺点,但它可能会让您入门。如果您想要一个真正的度量,那么请使用 Levenshtein 距离,它没有内置在数据库中(据我所知)。

于 2013-04-03T15:44:04.420 回答