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

LP:793386 - <single-table> Incorrect "Duplicate column name" with prepared statements in maria-5.3-mwl106

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Minor
    • Resolution: Fixed
    • None
    • None
    • None

    Description

      Not reproducible in maria-5.3. When executing a prepared statement twice, the second execution results in a 1060: 'Duplicate column name ''' error.

      Test case:

      CREATE TABLE t1 (
      f1 integer,
      f2 integer,
      f3 integer
      );
      INSERT INTO t1 VALUES (2, 0, 0),(2,0,0);

      CREATE VIEW v1 AS SELECT * FROM t1;

      PREPARE st1 FROM "
      SELECT
      alias1.f1 AS field1,
      alias1.f2 AS field2,
      alias1.f3 AS field3
      FROM ( v1 AS alias1 JOIN ( t1 AS alias2 JOIN t1 AS alias3 ON 1 = 1 ) ON 1 = 1 )
      ";

      EXECUTE st1;
      --error 0
      EXECUTE st1;

      bzr version-info:

      revision-id: <email address hidden>
      date: 2011-06-05 21:54:25 -0700
      build-date: 2011-06-06 09:58:05 +0300
      revno: 3027
      branch-nick: maria-5.3-mwl106

      Attachments

        Activity

          People

            igor Igor Babaev
            philipstoev Philip Stoev (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 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.