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

Table with ENGINE=SPIDER provides incorrect values after first row of data from query

    XMLWordPrintable

Details

    Description

      Create a source table (see import script attached spider_test.sql)

      On a database 10.6.21, create spider table that references the source:

      create schema if not exists Z214517;
      use Z214517;
      DROP TABLE IF EXISTS spider_test;
      CREATE TABLE `spider_test` (
        `col1` tinyint(3) NOT NULL,  `col2` smallint(5) NOT NULL,  
        `col3` mediumint(7) NOT NULL, `col4` tinyint(3) NOT NULL,  
        `col5` smallint(5) NOT NULL,  `col6` smallint(5) NOT NULL,
        `col7` tinyint(3) NOT NULL,  `val` double NOT NULL,  
      `upper` double DEFAULT NULL,  `lower` double DEFAULT NULL,
        PRIMARY KEY (`col1`,`col2`,`col3`,`col4`,`col5`,`col6`,`col7`)
      ) ENGINE=SPIDER COMMENT='wrapper "mysql", srv "dataNode1", table "spider_test"';
       
      SELECT
      col4 AS col1, col4 as x1, col4 as x2, col4 as x3, col4 as x4,
      0 as nothing1, 0 as nothing2,
      col4 as x5, col4 as x6, col4 as x7, col4 as x8
      FROM spider_test;
      limit 5;
      

      See attached image. The results of the query are incorrect from the second row of output. On version 10.6.19, the rows are correct. On 10.6.21, the rows are incorrect.

      Attachments

        Issue Links

          Activity

            People

              ycp Yuchen Pei
              edward Edward Stoever
              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.