Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Duplicate
-
10.3.27
-
None
-
Linux 5.4.0-53-generic #59~18.04.1-Ubuntu
Server version: 10.3.27-MariaDB-1:10.3.27+maria~bionic-log
Description
It was working before until this version. The clause "CHECK (ISNULL(code)=ISNULL(class))" now causes syntax error mistakenly. Please refer to screen capture for problem explanation and replication.
root@fusion:~# uname -a
Linux fusion 5.4.0-53-generic #59~18.04.1-Ubuntu SMP Wed Oct 21 12:14:56 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
root@fusion:~#
root@fusion:~# mysql fusion
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 39
Server version: 10.3.27-MariaDB-1:10.3.27+maria~bionic-log mariadb.org binary distribution
Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
MariaDB [fusion]> CREATE TABLE IF NOT EXISTS `test` (
-> `jmaster` varchar(18) COLLATE utf8_bin NOT NULL,
-> `class` varchar(2) COLLATE utf8_bin DEFAULT NULL,
-> `code` varchar(5) COLLATE utf8_bin DEFAULT NULL CHECK (ISNULL(code)=ISNULL(class)),
-> `id` int(11) NOT NULL AUTO_INCREMENT,
-> PRIMARY KEY (`id`)
-> ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '= (`class` is null)' at line 1
MariaDB [fusion]>
Attachments
Issue Links
- duplicates
-
MDEV-24194 View definition corruption
- Closed
-
MDEV-24226 10.3.26 rejects syntax that 10.3.25 accepts
- Closed
- is duplicated by
-
MDEV-24641 Check constraint parser incorrectly indicates syntax error
- Closed