Uploaded image for project: 'MariaDB ColumnStore'
  1. MariaDB ColumnStore
  2. MCOL-656

Error in LIKE behaviour

    XMLWordPrintable

Details

    • 2017-10

    Description

      From mailing list:

      CREATE TABLE `test_like` (
        `dep` varchar(2) DEFAULT NULL
      ) ENGINE=Columnstore DEFAULT CHARSET=utf8
       
      CREATE TABLE `test_like_my` (
        `dep` varchar(2) DEFAULT NULL
      ) ENGINE=MyISAM DEFAULT CHARSET=utf8
       
      INSERT INTO test_like VALUES ('05'),('5'),('50'),('10');
      INSERT INTO test_like_my VALUES ('05'),('5'),('50'),('10');
       
      SELECT * FROM test_like;                                     
      +------+
      | dep  |
      +------+
      | 05   |
      | 5    |
      | 50   |
      | 10   |
      +------+
       
       
      SELECT * FROM test_like_my;
      +------+
      | dep  |
      +------+
      | 05   |
      | 5    |
      | 50   |
      | 10   |
      +------+
      

      And 2 query on columnstore:

      SELECT count(*) FROM test_like  WHERE ( dep LIKE "05%" )  ;  
      +----------+
      | count(*) |
      +----------+
      |        1 |
      +----------+
      SELECT count(*) FROM test_like  WHERE ( dep LIKE "%05%" )  ;
      +----------+
      | count(*) |
      +----------+
      |        2 |
      +----------+
      

      And 2 query on MyIsam :

      SELECT count(*) FROM test_like_my  WHERE ( dep LIKE "05%" )  ;
      +----------+
      | count(*) |
      +----------+
      |        1 |
      +----------+
      SELECT count(*) FROM test_like_my  WHERE ( dep LIKE "%05%" )  ;
      +----------+
      | count(*) |
      +----------+
      |        1 |
      +----------+
      

      Attachments

        Activity

          People

            dleeyh Daniel Lee (Inactive)
            LinuxJedi Andrew Hutchings (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.