couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Julien Gagnet <julien.gag...@gmail.com>
Subject Does couchdb treat o or ø or ô the same way?
Date Wed, 15 Jun 2011 07:43:34 GMT
Hi,
First sorry if this was discussed but I couldn't find information.

Given a simple document:
{   "type": "user",   "name": "george"}

And a even more simple view to find user with the start of their username:
function(doc) {
  if (doc.type == "user"){
    emit(doc.name, doc);
  }
}
under User/user_by_name

If I query this view with the start key 'geo' I get the expected
'george' user back:
http://localhost:5984/test_db/_design/User/_view/user_by_name?startkey=%22geo%22&endkey=%22geo香%22

However if I search on geø or geô I still get george back:
http://localhost:5984/test_db/_design/User/_view/user_by_name?startkey=%22geø%22&endkey=%22geø香%22

I not saying it's a bug but I would like to understand why this is
happening. Is couch ignoring accented charater? How could I search for
"thé" (tea in french) and not getting back "the coffee"?

Thanks for helping.

Julien

Mime
View raw message