[MDEV-17827] INSERT .. PARTITION (partition_list) (column_list) VALUES ... syntax stopped working Created: 2018-11-25  Updated: 2019-04-05  Resolved: 2019-04-05

Status: Closed
Project: MariaDB Server
Component/s: Data Manipulation - Insert, Parser, Partitioning
Affects Version/s: 10.4
Fix Version/s: 10.4.4

Type: Bug Priority: Major
Reporter: Elena Stepanova Assignee: Igor Babaev
Resolution: Fixed Votes: 1
Labels: 10.4-rc, regression

Issue Links:
Duplicate
duplicates MDEV-18982 Partition pruning with column list ca... Closed

 Description   

https://mariadb.com/kb/en/library/insert/

The syntax documented by the page above

INSERT 
 INTO tbl_name PARTITION (partition_list) (col,...)
VALUES (expr,...),(...)

worked on 10.0-10.3, but not on 10.4:

MariaDB [test]> insert into tp partition (p1) (a) values (1);
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 'a) values (1)' at line 1
MariaDB [test]> select @@version;
+----------------------+
| @@version            |
+----------------------+
| 10.4.1-MariaDB-debug |
+----------------------+
1 row in set (0.00 sec)

MariaDB [test]> insert into tp partition (p1) (a) values (1);
Query OK, 1 row affected (0.04 sec)
 
MariaDB [test]> select @@version;
+-----------------------+
| @@version             |
+-----------------------+
| 10.3.12-MariaDB-debug |
+-----------------------+
1 row in set (0.00 sec)



 Comments   
Comment by Alexander Barkov [ 2018-11-28 ]

igor, can you please take over this MDEV?
It seems the problem is related to LEFT_PAREN_ALT introduced in 10.4.

Comment by Igor Babaev [ 2019-04-05 ]

A fix for this bug was pushed into 10.4

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