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

discover of table non-existance on CREATE

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 10.0.4
    • Fix Version/s: 10.0.7, 10.0.9
    • Component/s: None
    • Labels:
      None

      Description

      Discovery of table non-existance does not work for CREATE TABLE:

      create table t1 (a int) engine=archive;
      select * from t1;
      flush tables;
      remove_file $mysqld_datadir/test/t1.ARZ;
      create table t1 (a int) engine=archive;
      

      This fails with very unexpected 1146: Table 'test.t1' doesn't exist

        Gliffy Diagrams

          Attachments

            Activity

            Hide
            monty Michael Widenius added a comment -

            After implementing CREATE .. REPLACE and cleaning up the CREATE TABLE code so that we don't open the table anymore, the error for the above has changed to:

            Table 't1' already exists.

            This should be ok as the create can't go forward if the .frm already exists.

            If the .frm is also deleted then the CREATE will succeed.

            In case of discovery, it will happen on the next usage of the table.

            Show
            monty Michael Widenius added a comment - After implementing CREATE .. REPLACE and cleaning up the CREATE TABLE code so that we don't open the table anymore, the error for the above has changed to: Table 't1' already exists. This should be ok as the create can't go forward if the .frm already exists. If the .frm is also deleted then the CREATE will succeed. In case of discovery, it will happen on the next usage of the table.
            Hide
            serg Sergei Golubchik added a comment -

            I don't understand. The bug is fixed and closed. There is no error anymore in test case above.
            Have you reintroduced the error?

            Show
            serg Sergei Golubchik added a comment - I don't understand. The bug is fixed and closed. There is no error anymore in test case above. Have you reintroduced the error?
            Hide
            serg Sergei Golubchik added a comment -

            When CREATE-OR-REPLACE (MDEV-5491) is pushed, this will need to be fixed again

            Show
            serg Sergei Golubchik added a comment - When CREATE-OR-REPLACE ( MDEV-5491 ) is pushed, this will need to be fixed again

              People

              • Assignee:
                serg Sergei Golubchik
                Reporter:
                serg Sergei Golubchik
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 7 hours
                  7h