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

Columnstore query returns incorrect value instead of expected out-of-range error

Details

    • 2023-11

    Description

      create schema coltest; use coltest;
      drop table if exists test_mult;
      create table test_mult (
      indemnity_paid int(11),
      n_clms tinyint(3) unsigned
      ) engine=columnstore;
      insert into test_mult (indemnity_paid, n_clms) values (-10, 1);
      select indemnity_paid, n_clms, indemnity_paid * n_clms from test_mult;
      +----------------+--------+-------------------------+
      | indemnity_paid | n_clms | indemnity_paid * n_clms |
      +----------------+--------+-------------------------+
      |            -10 |      1 |    18446744073709551606 |
      +----------------+--------+-------------------------+
      

      The multiplication produces an incorrect value.
      For the same table defined engine=innodb, the multiplication produces an expected out-of-range error:

      alter table test_mult engine=innodb;
      select indemnity_paid, n_clms, indemnity_paid * n_clms from test_mult;
      ERROR 1690 (22003): BIGINT UNSIGNED value is out of range in '`coltest`.`test_mult`.`indemnity_paid` * `coltest`.`test_mult`.`n_clms`'
      

      Attachments

        Activity

          edward Edward Stoever created issue -
          toddstoffel Todd Stoffel (Inactive) made changes -
          Field Original Value New Value
          Rank Ranked higher
          toddstoffel Todd Stoffel (Inactive) made changes -
          Rank Ranked lower
          edward Edward Stoever made changes -
          Labels triage
          alexey.vorovich alexey vorovich (Inactive) made changes -
          Labels triage mcs_cs_ncci triage
          alexey.vorovich alexey vorovich (Inactive) made changes -
          Assignee Sergey Zefirov [ JIRAUSER47362 ]
          alexey.vorovich alexey vorovich (Inactive) made changes -
          Fix Version/s 23.10.1 [ 29105 ]
          alexey.vorovich alexey vorovich (Inactive) made changes -
          Status Open [ 1 ] In Progress [ 3 ]
          alexey.vorovich alexey vorovich (Inactive) made changes -
          Labels mcs_cs_ncci triage mcs_cs_ncci rm_invalid_data triage
          alexey.vorovich alexey vorovich (Inactive) made changes -
          Sprint 2023-11 [ 737 ]
          drrtuy Roman made changes -
          Status In Progress [ 3 ] In Testing [ 10301 ]
          drrtuy Roman made changes -
          Assigned for Review Roman [ drrtuy ]
          Assigned for Testing Kirill Perov [ JIRAUSER51446 ]
          julien.fritsch Julien Fritsch made changes -
          Labels mcs_cs_ncci rm_invalid_data triage rm_invalid_data triage
          allen.herrera Allen Herrera made changes -
          Resolution Fixed [ 1 ]
          Status In Testing [ 10301 ] Closed [ 6 ]
          mariadb-jira-automation Jira Automation (IT) made changes -
          Zendesk Related Tickets 155608

          People

            sergey.zefirov Sergey Zefirov
            edward Edward Stoever
            Roman Roman
            Kirill Perov Kirill Perov (Inactive)
            Votes:
            1 Vote for this issue
            Watchers:
            8 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.