[MDEV-15121] ER_UNSUPPORTED_EXTENSION when using ON DELETE CASCADE Created: 2018-01-30  Updated: 2018-02-05  Resolved: 2018-02-05

Status: Closed
Project: MariaDB Server
Component/s: Versioned Tables
Affects Version/s: 10.3.4
Fix Version/s: N/A

Type: Bug Priority: Major
Reporter: Benjamin Bartels Assignee: Unassigned
Resolution: Duplicate Votes: 0
Labels: None
Environment:

Windows 10 64Bit; Ubuntu 17.10 64Bit


Issue Links:
Relates
relates to MDEV-15136 'delete from user where username = "a... Closed
relates to MDEV-14681 Bogus ER_UNSUPPORTED_EXTENSION (Table... Closed

 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";



 Comments   
Comment by Benjamin Bartels [ 2018-01-31 ]

Eugene Kosov Can be closed, fixed in MDEV-1536.

Comment by Elena Stepanova [ 2018-02-05 ]

Sorry for closing as a "duplicate", your report was earlier and should be kept as an original, but since MDEV-15136 already has a patch, it makes sense to track it there.

Generated at Thu Feb 08 08:18:50 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.