1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-27 18:02:13 +03:00

Merge branch '11.1' into 11.2

This commit is contained in:
Oleksandr Byelkin
2024-08-03 09:50:16 +02:00
463 changed files with 12095 additions and 5097 deletions

View File

@ -433,8 +433,8 @@ gc geometrycollection YES NULL
gm geometry YES NULL
fid int(11) NO NULL
DROP TABLE t1;
SELECT ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_GeometryFromText('POINT(1 4)'))));
ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_GeometryFromText('POINT(1 4)'))))
SELECT ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_GeometryFromText('POINT(1 4)')))) AS val;
val
POINT(1 4)
explain extended SELECT ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_GeometryFromText('POINT(1 4)'))));
id select_type table type possible_keys key key_len ref rows filtered Extra
@ -668,11 +668,11 @@ ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
insert into t1 values (ST_pointfromtext('point(1,1)'));
ERROR 23000: Column 'fl' cannot be null
drop table t1;
select (ST_asWKT(ST_geomfromwkb((0x000000000140240000000000004024000000000000))));
(ST_asWKT(ST_geomfromwkb((0x000000000140240000000000004024000000000000))))
select (ST_asWKT(ST_geomfromwkb((0x000000000140240000000000004024000000000000)))) AS val;
val
POINT(10 10)
select (ST_asWKT(ST_geomfromwkb((0x010100000000000000000024400000000000002440))));
(ST_asWKT(ST_geomfromwkb((0x010100000000000000000024400000000000002440))))
select (ST_asWKT(ST_geomfromwkb((0x010100000000000000000024400000000000002440)))) AS val;
val
POINT(10 10)
create table t1 (g GEOMETRY);
select * from t1;

View File

@ -434,8 +434,8 @@ gc geometrycollection YES NULL
gm geometry YES NULL
fid int(11) NO NULL
DROP TABLE t1;
SELECT ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_GeometryFromText('POINT(1 4)'))));
ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_GeometryFromText('POINT(1 4)'))))
SELECT ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_GeometryFromText('POINT(1 4)')))) AS val;
val
POINT(1 4)
explain extended SELECT ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_GeometryFromText('POINT(1 4)'))));
id select_type table type possible_keys key key_len ref rows filtered Extra
@ -669,11 +669,11 @@ ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
insert into t1 values (ST_pointfromtext('point(1,1)'));
ERROR 23000: Column 'fl' cannot be null
drop table t1;
select (ST_asWKT(ST_geomfromwkb((0x000000000140240000000000004024000000000000))));
(ST_asWKT(ST_geomfromwkb((0x000000000140240000000000004024000000000000))))
select (ST_asWKT(ST_geomfromwkb((0x000000000140240000000000004024000000000000)))) AS val;
val
POINT(10 10)
select (ST_asWKT(ST_geomfromwkb((0x010100000000000000000024400000000000002440))));
(ST_asWKT(ST_geomfromwkb((0x010100000000000000000024400000000000002440))))
select (ST_asWKT(ST_geomfromwkb((0x010100000000000000000024400000000000002440)))) AS val;
val
POINT(10 10)
create table t1 (g GEOMETRY);
select * from t1;

View File

@ -136,17 +136,20 @@ SELECT fid, ST_AsText(ST_GeometryN(g, 1)) from gis_geometrycollection;
--replace_column 9 # 10 #
explain extended SELECT fid, ST_AsText(ST_GeometryN(g, 2)) from gis_multi_point;
--disable_view_protocol
SELECT g1.fid as first, g2.fid as second,
MBRWithin(g1.g, g2.g) as w, MBRContains(g1.g, g2.g) as c, MBROverlaps(g1.g, g2.g) as o,
MBREquals(g1.g, g2.g) as e, MBRDisjoint(g1.g, g2.g) as d, ST_Touches(g1.g, g2.g) as t,
MBRIntersects(g1.g, g2.g) as i, ST_Crosses(g1.g, g2.g) as r
FROM gis_geometrycollection g1, gis_geometrycollection g2 ORDER BY first, second;
--replace_column 9 # 10 #
explain extended SELECT g1.fid as first, g2.fid as second,
MBRWithin(g1.g, g2.g) as w, MBRContains(g1.g, g2.g) as c, MBROverlaps(g1.g, g2.g) as o,
MBREquals(g1.g, g2.g) as e, MBRDisjoint(g1.g, g2.g) as d, ST_Touches(g1.g, g2.g) as t,
MBRIntersects(g1.g, g2.g) as i, ST_Crosses(g1.g, g2.g) as r
FROM gis_geometrycollection g1, gis_geometrycollection g2 ORDER BY first, second;
--enable_view_protocol
DROP TABLE gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gis_multi_polygon, gis_geometrycollection, gis_geometry;
@ -169,7 +172,7 @@ ALTER TABLE t1 ADD fid INT NOT NULL;
SHOW FIELDS FROM t1;
DROP TABLE t1;
SELECT ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_GeometryFromText('POINT(1 4)'))));
SELECT ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_GeometryFromText('POINT(1 4)')))) AS val;
explain extended SELECT ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_GeometryFromText('POINT(1 4)'))));
explain extended SELECT ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_PointFromText('POINT(1 4)'))));
SELECT ST_SRID(ST_GeomFromText('LineString(1 1,2 2)',101));
@ -398,14 +401,16 @@ insert into t1 values (ST_pointfromtext('point(1,1)'));
drop table t1;
select (ST_asWKT(ST_geomfromwkb((0x000000000140240000000000004024000000000000))));
select (ST_asWKT(ST_geomfromwkb((0x010100000000000000000024400000000000002440))));
select (ST_asWKT(ST_geomfromwkb((0x000000000140240000000000004024000000000000)))) AS val;
select (ST_asWKT(ST_geomfromwkb((0x010100000000000000000024400000000000002440)))) AS val;
--disable_view_protocol
--enable_metadata
create table t1 (g GEOMETRY);
select * from t1;
select ST_asbinary(g) from t1;
--disable_metadata
--enable_view_protocol
drop table t1;
create table t1 (a TEXT, b GEOMETRY NOT NULL, INDEX(b(5)));

View File

@ -625,17 +625,20 @@ SELECT fid, ST_AsText(ST_GeometryN(g, 1)) from gis_geometrycollection;
--replace_column 9 #
explain extended SELECT fid, ST_AsText(ST_GeometryN(g, 2)) from gis_multi_point;
--disable_view_protocol
SELECT g1.fid as first, g2.fid as second,
MBRWithin(g1.g, g2.g) as w, MBRContains(g1.g, g2.g) as c, MBROverlaps(g1.g, g2.g) as o,
MBREquals(g1.g, g2.g) as e, MBRDisjoint(g1.g, g2.g) as d, ST_Touches(g1.g, g2.g) as t,
MBRIntersects(g1.g, g2.g) as i, ST_Crosses(g1.g, g2.g) as r
FROM gis_geometrycollection g1, gis_geometrycollection g2 ORDER BY first, second;
--replace_column 9 #
explain extended SELECT g1.fid as first, g2.fid as second,
MBRWithin(g1.g, g2.g) as w, MBRContains(g1.g, g2.g) as c, MBROverlaps(g1.g, g2.g) as o,
MBREquals(g1.g, g2.g) as e, MBRDisjoint(g1.g, g2.g) as d, ST_Touches(g1.g, g2.g) as t,
MBRIntersects(g1.g, g2.g) as i, ST_Crosses(g1.g, g2.g) as r
FROM gis_geometrycollection g1, gis_geometrycollection g2 ORDER BY first, second;
--enable_view_protocol
--echo # check support of Foreign Key constraint
CREATE TABLE parent (id GEOMETRY NOT NULL,PRIMARY KEY (id(10))) ENGINE=INNODB;

View File

@ -133,17 +133,20 @@ SELECT fid, ST_AsText(ST_GeometryN(g, 1)) from gis_geometrycollection;
--replace_column 9 #
explain extended SELECT fid, ST_AsText(ST_GeometryN(g, 2)) from gis_multi_point;
--disable_view_protocol
SELECT g1.fid as first, g2.fid as second,
MBRWithin(g1.g, g2.g) as w, MBRContains(g1.g, g2.g) as c, MBROverlaps(g1.g, g2.g) as o,
MBREquals(g1.g, g2.g) as e, MBRDisjoint(g1.g, g2.g) as d, ST_Touches(g1.g, g2.g) as t,
MBRIntersects(g1.g, g2.g) as i, ST_Crosses(g1.g, g2.g) as r
FROM gis_geometrycollection g1, gis_geometrycollection g2 ORDER BY first, second;
--replace_column 9 #
explain extended SELECT g1.fid as first, g2.fid as second,
MBRWithin(g1.g, g2.g) as w, MBRContains(g1.g, g2.g) as c, MBROverlaps(g1.g, g2.g) as o,
MBREquals(g1.g, g2.g) as e, MBRDisjoint(g1.g, g2.g) as d, ST_Touches(g1.g, g2.g) as t,
MBRIntersects(g1.g, g2.g) as i, ST_Crosses(g1.g, g2.g) as r
FROM gis_geometrycollection g1, gis_geometrycollection g2 ORDER BY first, second;
--enable_view_protocol
DROP TABLE gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gis_multi_polygon, gis_geometrycollection, gis_geometry;
@ -166,7 +169,7 @@ ALTER TABLE t1 ADD fid INT NOT NULL;
SHOW FIELDS FROM t1;
DROP TABLE t1;
SELECT ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_GeometryFromText('POINT(1 4)'))));
SELECT ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_GeometryFromText('POINT(1 4)')))) AS val;
explain extended SELECT ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_GeometryFromText('POINT(1 4)'))));
explain extended SELECT ST_AsText(ST_GeometryFromWKB(ST_AsWKB(ST_PointFromText('POINT(1 4)'))));
SELECT ST_SRID(ST_GeomFromText('LineString(1 1,2 2)',101));
@ -391,14 +394,16 @@ insert into t1 values (ST_pointfromtext('point(1,1)'));
drop table t1;
select (ST_asWKT(ST_geomfromwkb((0x000000000140240000000000004024000000000000))));
select (ST_asWKT(ST_geomfromwkb((0x010100000000000000000024400000000000002440))));
select (ST_asWKT(ST_geomfromwkb((0x000000000140240000000000004024000000000000)))) AS val;
select (ST_asWKT(ST_geomfromwkb((0x010100000000000000000024400000000000002440)))) AS val;
--disable_view_protocol
--enable_metadata
create table t1 (g GEOMETRY);
select * from t1;
select ST_asbinary(g) from t1;
--disable_metadata
--enable_view_protocol
drop table t1;
create table t1 (a TEXT, b GEOMETRY NOT NULL, SPATIAL KEY(b));