Details
-
Bug
-
Resolution: Done
-
Minor - P4
-
2.4.0, 2.4.1, 2.4.2, 2.4.3
-
ALL
Description
> use test2
|
switched to db test2
|
> db.tweets.save( {_id:1,comments:["this is important",{b:"this is unimportant"},"green",{b:"blue"}]} ); |
> db.tweets.ensureIndex({ "comments.b" : "text" }); |
> db.tweets.runCommand("text",{ search : "unimportant" }); |
{
|
"queryDebugString" : "unimport||||||", |
"language" : "english", |
"results" : [ |
{
|
"score" : 1, |
"obj" : { |
"_id" : 1, |
"comments" : [ |
"this is important", |
{
|
"b" : "this is unimportant" |
},
|
"green", |
{
|
"b" : "blue" |
}
|
]
|
}
|
}
|
],
|
"stats" : { |
"nscanned" : 1, |
"nscannedObjects" : 0, |
"n" : 1, |
"nfound" : 1, |
"timeMicros" : 122 |
},
|
"ok" : 1 |
}
|
> db.tweets.runCommand("text",{ search : "important" }); |
{
|
"queryDebugString" : "import||||||", |
"language" : "english", |
"results" : [ |
{
|
"score" : 1, |
"obj" : { |
"_id" : 1, |
"comments" : [ |
"this is important", |
{
|
"b" : "this is unimportant" |
},
|
"green", |
{
|
"b" : "blue" |
}
|
]
|
}
|
}
|
],
|
"stats" : { |
"nscanned" : 1, |
"nscannedObjects" : 0, |
"n" : 1, |
"nfound" : 1, |
"timeMicros" : 89 |
},
|
"ok" : 1 |
}
|
Attachments
Issue Links
- has to be done before
-
SERVER-10906 Support for legacy text index format textIndexVersion:1
-
- Closed
-