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

ER_UNSUPPORTED_EXTENSION when using ON DELETE CASCADE

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Duplicate
    • 10.3.4
    • N/A
    • Versioned Tables
    • None
    • Windows 10 64Bit; Ubuntu 17.10 64Bit

    Description

      I was testing out the new system-versioned tables and stumbled upon the ER_UNSUPPORTED_EXTENSION
      when using ON DELETE CASCADE in my table definition.

      DROP DATABASE IF EXISTS test;
      CREATE DATABASE test;
      USE test;
       
      CREATE TABLE User
      (
          Id               INT AUTO_INCREMENT PRIMARY KEY,
          Username         VARCHAR(50) NOT NULL
      ) WITH SYSTEM VERSIONING;
       
       
      CREATE TABLE Products
      (
          Id                INT AUTO_INCREMENT PRIMARY KEY,
          Name              VARCHAR(100) NOT NULL,
          ModifiedBy        INT NOT NULL,
          FOREIGN KEY(ModifiedBy) REFERENCES User(Id) ON DELETE CASCADE
      ) WITH SYSTEM VERSIONING;
       
       
      INSERT INTO User(Username) VALUES ("admin");
       
      INSERT INTO Products(Name, ModifiedBy) VALUES ("Apple", 1);
      #Error is thrown on the delete
      DELETE FROM User WHERE Username = "admin";
      

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              bbartels Benjamin Bartels
              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.