mirror of
https://github.com/MariaDB/server.git
synced 2025-08-07 00:04:31 +03:00
reject invalid spatial key declarations in the parser
This commit is contained in:
@@ -1,3 +1,29 @@
|
||||
create table t1 (g geometry not null, spatial key(g(10)));
|
||||
ERROR 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 '(10)))' at line 1
|
||||
create table t1 (g geometry not null, spatial key(g asc));
|
||||
ERROR 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 'asc))' at line 1
|
||||
create table t1 (g geometry not null, spatial key(g desc));
|
||||
ERROR 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 'desc))' at line 1
|
||||
create table t1 (g geometry not null, f geometry not null, spatial key(g,f));
|
||||
ERROR 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 'f))' at line 1
|
||||
create table t1 (g geometry not null, f geometry not null);
|
||||
create spatial index bad on t1 (g(10));
|
||||
ERROR 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 '(10))' at line 1
|
||||
create spatial index bad on t1 (g asc);
|
||||
ERROR 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 'asc)' at line 1
|
||||
create spatial index bad on t1 (g desc);
|
||||
ERROR 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 'desc)' at line 1
|
||||
create spatial index bad on t1 (f,g);
|
||||
ERROR 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 'g)' at line 1
|
||||
alter table t1 add spatial index bad (g(10));
|
||||
ERROR 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 '(10))' at line 1
|
||||
alter table t1 add spatial index bad (g asc);
|
||||
ERROR 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 'asc)' at line 1
|
||||
alter table t1 add spatial index bad (g desc);
|
||||
ERROR 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 'desc)' at line 1
|
||||
alter table t1 add spatial index bad (f,g);
|
||||
ERROR 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 'g)' at line 1
|
||||
drop table t1;
|
||||
CREATE TABLE t1 (
|
||||
fid INT NOT NULL AUTO_INCREMENT PRIMARY KEY,
|
||||
g GEOMETRY NOT NULL,
|
||||
|
Reference in New Issue
Block a user