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

Temporary table name conflict between sessions

    XMLWordPrintable

Details

    Description

      If we create a temporary table with the same name within a store procedure, and try to drop some columns in two different sessions running at the same moment, error " Unknown column" may pop.

      Although this is documented in

      https://mariadb.com/kb/en/mariadb/documentation/sql-commands/data-definition/create/create-table/

      "Temporary table names are specific to your session. They may conflict with other temporary tables from other sessions or shadow names of non-temporary tables."

      But this is different behavior with Mysql

      http://dev.mysql.com/doc/refman/5.5/en/create-table.html

      This means that two different sessions can use the same temporary table name without conflicting with each other or with an existing non-TEMPORARY table of the same name. (The existing table is hidden until the temporary table is dropped.)

      This is stopper if using Mariadb as a drop in replacement for Mysql, as this require rewrite all SPs with alter temporary statement.

      Attachments

        Issue Links

          Activity

            People

              serg Sergei Golubchik
              leomkkwan Leo Kwan
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0d
                  0d
                  Logged:
                  Time Spent - 0.5h
                  0.5h

                  Git Integration

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