Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-32076

Unexpected Results by not_null_range_scan

    XMLWordPrintable

Details

    • Bug
    • Status: Confirmed (View Workflow)
    • Major
    • Resolution: Unresolved
    • 10.5, 10.6, 10.9, 10.10, 10.11, 11.0, 11.1.2
    • 10.5, 10.6, 10.11, 11.1
    • Optimizer
    • None
    • Docker: mariadb:lates

    Description

      By changing the setting: not_null_range_scan, a query returns different results shown as follows.

      CREATE TABLE t0(c0 CHAR UNIQUE);
      INSERT INTO t0 VALUES (DEFAULT);

      SET SESSION optimizer_switch = 'not_null_range_scan=off';
      SELECT c0 FROM t0 WHERE (TRUE NOT IN (LOCATE(1, false, c0))); –

      {NULL}

      SET SESSION optimizer_switch = 'not_null_range_scan=on';
      SELECT c0 FROM t0 WHERE (TRUE NOT IN (LOCATE(1, false, c0))); – {}

      Attachments

        Activity

          People

            psergei Sergei Petrunia
            bajinsheng Jinsheng Ba
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:

              Git Integration

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