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

CREATE TABLE IF NOT EXISTS throws an error instead of warning if the table is locked

    XMLWordPrintable

Details

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

    Description

      The following test case

      create table t1 (i int);
      lock table t1 read;
       
      --connect (con1,localhost,root,,)
      # Should produce warning 1050 "Table '<name>' already exists"
      create table if not exists t1 (j int);
      --disconnect con1
       
      --connection default
      unlock tables;
      drop table t1;
       

      fails with an error:

      mysqltest: At line 6: query 'create table if not exists t1 (j int)' failed: 1050: Table 't1' already exists

      It's a serious change in behavior which most likely won't be welcome in a GA version.

      branch: maria/5.5
      revision-id: timour@askmonty.org-20121217132358-6af27lb65kf5kwf2
      date: 2012-12-17 15:23:58 +0200
      build-date: 2012-12-18 00:25:33 +0400
      revno: 3596

      Attachments

        Issue Links

          Activity

            People

              monty Michael Widenius
              elenst Elena Stepanova
              Votes:
              0 Vote for this issue
              Watchers:
              2 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.