MongoDB Full Text Search case-insensitive or not?

69 views Asked by At

Following docs (http://docs.mongodb.org/manual/tutorial/search-for-text/) text index must be case-insensitive. But as I see:

> db.procedures2.runCommand("text",{project:{_id:1}, 
      search:"иркутск",language:"russian",limit:1})**

{
"queryDebugString" : "иркутск||||||",
"language" : "russian",
"results" : [ ],
"stats" : {
    "nscanned" : 0,
    "nscannedObjects" : 0,
    "n" : 0,
    "nfound" : 0,
    "timeMicros" : 170
},
"ok" : 1
}

nothing found


> db.procedures2.runCommand("text",{project:{_id:1}, 
    search:"Иркутск",language:"russian",limit:1})**

{
"queryDebugString" : "Иркутск||||||",
"language" : "russian",
"results" : [
    {
        "score" : 0.984375,
        "obj" : {
            "_id" : ObjectId("5299b9635497c868430266a0")
        }
    }
],
"stats" : {
    "nscanned" : 163,
    "nscannedObjects" : 0,
    "n" : 1,
    "nfound" : 1,
    "timeMicros" : 596
},
"ok" : 1
}

Found 1 record.

Why?

0

There are 0 answers