Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-26658

Full Text returns wrong results for Turkish

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major - P3
    • Resolution: Unresolved
    • Affects Version/s: 3.2.10, 3.3.15, 3.4.0-rc0
    • Fix Version/s: Backlog
    • Component/s: Text Search
    • Labels:
      None
    • Operating System:
      ALL

      Description

      The text index version 3 does not provide correct search result when the word contains "Turkish i" char.

      Create Script

      db.turk.drop()
      db.turk.insert({ _id: "small_dotless", t1 : "quıt" })
      db.turk.insert({ _id: "small_dot", t1 : "quit" })
      db.turk.insert({ _id: "big_dotless", t1 : "QUIT" })
      db.turk.insert({ _id: "big_dot", t1 : "QUİT" })
       
      db.turk.ensureIndex({t1: "text"}, {
          default_language: "turkish",
          name: "TextIndex"
      });
      

      Actual Results

      > db.turk.find({$text: {$search: "quit", $language: "tr", $caseSensitive: false, $diacriticSensitive: false}});
      {"_id" : "big_dot", "t1" : "QUİT"}
      {"_id" : "small_dot", "t1" : "quit"}
      

      Expected Results

      > db.turk.find({$text: {$search: "quit", $language: "tr", $caseSensitive: false, $diacriticSensitive: false}});
      {"_id" : "small_dotless", "t1" : "quıt"}
      {"_id" : "small_dot", "t1" : "quit"}
      {"_id" : "big_dotless", "t1" : "QUIT"}
      {"_id" : "big_dot", "t1" : "QUİT"}
      

        Attachments

          Activity

            People

            • Votes:
              2 Vote for this issue
              Watchers:
              13 Start watching this issue

              Dates

              • Created:
                Updated: