Christophe Leske <i...@multimedial.de> wrote: > - how can SQlite be instructed to return search results which include > a > special character in it? > E.g. you search literally for "Zurich" on an englisch system and > expect > "Zürich" to be in the result set.
You write your own comparison function that would consider these two strings equal. See sqlite3_create_function, sqlite3_create_collation. > The next problem is that educated users might know that german Umlaute > can be written out. The rules are simple: > > ä becomes "ae" > ö becomes "oe" > ü becomes "ue" > > So how would I go about filtering an educated user which looks for > "Zuerich" and expects "Zürich" in the result set? The same way. > Best find on my behalf so far is to build a filter which replaces any > occurence of "ae", "oe", "ue" with two placeholders ("%") Why would you ever want two % in a row? A % matches zero or more of arbitrary characters. You might be thinking of an underscore _. > So far , so good, but my client also expects ANY simplification of a > character to be recognized: > Cote d'azur for instance should return "Côte d'azur" > or the Sao Paulo issue - how can a search for "Sao Paulo" return "Sào > Paulo" in the result set? How are these examples different from previous ones? Igor Tandetnik
_______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users