Uploaded image for project: 'Derby'
  1. Derby
  2. DERBY-3080

With TERRITORY_BASED collation, when multiple characters map to a single collation element '_' matches a single collation element rather than a single character

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 10.3.1.4, 10.4.1.3
    • 10.3.2.1, 10.4.1.3
    • SQL
    • None

    Description

      '_' matches a single collation element rather than a single character if multiple characters have a single collation element. Below is an example with norwegian aa This occurs also with the patch for DERBY-2967 which addresses the case of matching of a single character having more than one collation element.

      ij> connect 'jdbc:derby:wombat;create=true;territory=no_NO;collation=TERRITORY_BASED';
      ij> drop table t;
      0 rows inserted/updated/deleted
      ij> create table t (vc varchar(30));
      0 rows inserted/updated/deleted
      ij> insert into t values('middleaavalue');
      1 row inserted/updated/deleted
      – The query below should match
      ij> select * from t where vc like 'middle__value';
      VC
      ------------------------------

      0 rows selected
      – The query below should not match.
      ij> select * from t where vc like 'middle_value';
      VC
      ------------------------------
      middleaavalue

      Attachments

        Activity

          People

            mamtas Mamta A. Satoor
            kmarsden Katherine Marsden
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: