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

After loading saved optimizer context, further queries cause errors

    XMLWordPrintable

Details

    Description

      Bug found while testing MDEV-38701

      insert into t2 select seq from seq_1_to_10;
      ERROR 4254 (HY000): Failed to match the stats from replay context with the optimizer stats: m8.seq_1_to_10 doesn't exist in list of table contexts.

      Repro steps:

      create database if not exists m8;use m8;
      drop table t1;
      create table t1(a int);
      set optimizer_record_context=ON;
      explain select * from t1;
      SELECT context INTO DUMPFILE 'context1.txt' FROM INFORMATION_SCHEMA.OPTIMIZER_CONTEXT;
       
      source data2/m8/context1.txt;
      drop table if exists t2;
      create table t2( a int);
      insert into t2 select seq from seq_1_to_10;
      

      Attachments

        Issue Links

          Activity

            People

              bsrikanth Srikanth Bondalapati
              mariadb-pavithrapandith Pavithra Pandith
              Votes:
              0 Vote for this issue
              Watchers:
              3 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.