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

toLowerCase() function does not work for Turkish char "İ"

    • Type: Icon: Bug Bug
    • Resolution: Duplicate
    • Priority: Icon: Minor - P4 Minor - P4
    • None
    • Affects Version/s: 2.4.1
    • Component/s: Shell
    • Environment:
    • Linux

      trynig toLowerCase the following word "ŞİŞLİ" on mongo shell

      at the version 2.2.3 this function work properly for turkish people.

      "ŞİŞLİ".toLowerCase() is "şişli"

      but with version 2.4.1 wi get double dot on "ı".
      telman@telman:~$ mongo --version
      MongoDB shell version: 2.4.1
      telman@telman:~$ mongo uysdb
      MongoDB shell version: 2.4.1
      connecting to: uysdb
      > "ŞİŞLİ".toLowerCase()
      şi̇şli̇ //the exact "i" char here have double dot instead of one.
      >

      I guess you tried to make a support for "İ" char. but the function is wrong

      currently I handle this state as below.

      this is what the turkish people expected.

      the proble is : we have to different character regradin to engli i.

      1) I and 2) İ and each lower case of that charcter is just the small version
      1) ı and 2) i

      breafly it have to be Iı and İi

      String.prototype.toTurkishLowerCase = function(){
      str = this.replace(/I/g,"ı").replace(/İ/g,"i");//otherwise it
      return str.toLowerCase()
      };

      Thanks for you efforts.

      best regards
      telman

            Assignee:
            matt.kangas Matt Kangas
            Reporter:
            shahbazov telman shahbazov
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: