Text matcher uses incorrect language for negation match

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Done
    • Priority: Major - P3
    • 2.6.0-rc0
    • Affects Version/s: 2.5.4
    • Component/s: Text Search
    • None
    • ALL
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      The text negation matcher parses the document using the search language. It should instead be parsing the document with the document language.

      > db.foo.insert({_id:0, a:"gladly 007"})
      > db.foo.ensureIndex({a:"text"})
      > db.foo.find({$text:{$search:"glad", $language:"spanish"}})
      { "_id" : 0, "a" : "gladly 007" }
      > db.foo.find({$text:{$search:"007 -glad", $language:"spanish"}})
      { "_id" : 0, "a" : "gladly 007" } // incorrect, not caught by negation because "gladly" stemmed with Spanish stemmer
      >
      

            Assignee:
            J Rassi (Inactive)
            Reporter:
            J Rassi (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: