summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2020-03-19 06:58:49 +0200
committerMarko Mäkelä <marko.makela@mariadb.com>2020-03-19 06:58:49 +0200
commite28b4b68d344391c94ab582445f26db4fd12927e (patch)
tree3015907893efd92adbfbcad68d7e4ed153099dab /mysql-test
parenta0ce62f804dc1a0073688bea46dc2e6728cf55e3 (diff)
downloadmariadb-git-e28b4b68d344391c94ab582445f26db4fd12927e.tar.gz
MDEV-14057: Fix some tests
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/suite/innodb_gis/r/point_big.result18
-rw-r--r--mysql-test/suite/innodb_gis/r/rtree_concurrent_srch.result2
-rw-r--r--mysql-test/suite/innodb_gis/r/rtree_split.result4
3 files changed, 17 insertions, 7 deletions
diff --git a/mysql-test/suite/innodb_gis/r/point_big.result b/mysql-test/suite/innodb_gis/r/point_big.result
index de3632994a0..c471ab6adb2 100644
--- a/mysql-test/suite/innodb_gis/r/point_big.result
+++ b/mysql-test/suite/innodb_gis/r/point_big.result
@@ -259,10 +259,8 @@ INSERT INTO gis_point VALUES
(ST_PointFromText('POINT(32.1234 64.2468)'), ST_PointFromText('POINT(-1 -1)'));
'The ORDER BY for spatial index will use filesort'
EXPLAIN SELECT ST_AsText(p1), ST_AsText(p2) FROM gis_point ORDER BY p1, p2;
-id select_type table partitions type possible_keys key key_len ref rows filtered Extra
-1 SIMPLE gis_point NULL ALL NULL NULL NULL NULL # 100.00 Using filesort
-Warnings:
-Note 1003 /* select#1 */ select st_astext(`test`.`gis_point`.`p1`) AS `ST_AsText(p1)`,st_astext(`test`.`gis_point`.`p2`) AS `ST_AsText(p2)` from `test`.`gis_point` order by `test`.`gis_point`.`p1`,`test`.`gis_point`.`p2`
+id select_type table type possible_keys key key_len ref rows Extra
+1 SIMPLE gis_point ALL NULL NULL NULL NULL 13 #
SELECT ST_AsText(p1), ST_AsText(p2) FROM gis_point ORDER BY p1, p2;
ST_AsText(p1) ST_AsText(p2)
POINT(2 4) POINT(-2 -6)
@@ -354,9 +352,11 @@ COUNT(*) ST_AsText(p1)
1024 POINT(4 8)
SELECT COUNT(*), ST_AsText(p2) FROM gis_point WHERE ST_Contains(@poly2, p2) GROUP BY p2;
COUNT(*) ST_AsText(p2)
+1024 POINT(0 0)
1024 POINT(-2 -6)
1024 POINT(-3 -9)
1024 POINT(-4 -12)
+1024 POINT(-5 -15)
1024 POINT(-1 -3)
1024 POINT(-1 -1)
SELECT COUNT(*), ST_AsText(p2) FROM gis_point WHERE ST_Equals(p2, @p1) GROUP BY p2;
@@ -368,13 +368,17 @@ COUNT(*) ST_AsText(p1)
1024 POINT(32.1234 64.2468)
SELECT COUNT(*), ST_AsText(p1), ST_AsText(p2) FROM gis_point WHERE ST_Contains(@mpoly, p1) GROUP BY p1, p2;
COUNT(*) ST_AsText(p1) ST_AsText(p2)
+1024 POINT(3 6) POINT(-3 -9)
1024 POINT(4 8) POINT(-4 -12)
1024 POINT(5 10) POINT(-5 -15)
1024 POINT(6 12) POINT(-6 -18)
1024 POINT(7 14) POINT(-7 -21)
+1024 POINT(8 16) POINT(0 0)
+1024 POINT(10 21) POINT(-6 3)
1024 POINT(20.5 41) POINT(-8 4)
SELECT COUNT(*), ST_AsText(p1), ST_AsText(p2) FROM gis_point WHERE ST_Contains(@mpoly, p1) AND NOT MBRWithin(p1, @mpoly) GROUP BY p1, p2;
COUNT(*) ST_AsText(p1) ST_AsText(p2)
+1024 POINT(3 6) POINT(-3 -9)
======================================================================
Build another new table with the same schema, will insert data from this table to the orignal one
======================================================================
@@ -522,9 +526,11 @@ COUNT(*) ST_AsText(p1)
1024 POINT(4 8)
SELECT COUNT(*), ST_AsText(p2) FROM gis_point WHERE ST_Contains(@poly2, p2) GROUP BY p2;
COUNT(*) ST_AsText(p2)
+2 POINT(0 0)
1024 POINT(-2 -6)
1024 POINT(-3 -9)
1024 POINT(-4 -12)
+1024 POINT(-5 -15)
1024 POINT(-1 -3)
1024 POINT(-1 -1)
SELECT COUNT(*), ST_AsText(p2) FROM gis_point WHERE ST_Equals(p2, @p1) GROUP BY p2;
@@ -536,13 +542,17 @@ COUNT(*) ST_AsText(p1)
1024 POINT(32.1234 64.2468)
SELECT COUNT(*), ST_AsText(p1), ST_AsText(p2) FROM gis_point WHERE ST_Contains(@mpoly, p1) GROUP BY p1, p2;
COUNT(*) ST_AsText(p1) ST_AsText(p2)
+1024 POINT(3 6) POINT(-3 -9)
1024 POINT(4 8) POINT(-4 -12)
1024 POINT(5 10) POINT(-5 -15)
1024 POINT(6 12) POINT(-6 -18)
1024 POINT(7 14) POINT(-7 -21)
+2 POINT(8 16) POINT(0 0)
+1024 POINT(10 21) POINT(-6 3)
1024 POINT(20.5 41) POINT(-8 4)
SELECT COUNT(*), ST_AsText(p1), ST_AsText(p2) FROM gis_point WHERE ST_Contains(@mpoly, p1) AND NOT MBRWithin(p1, @mpoly) GROUP BY p1, p2;
COUNT(*) ST_AsText(p1) ST_AsText(p2)
+1024 POINT(3 6) POINT(-3 -9)
CHECK TABLE gis_point;
Table Op Msg_type Msg_text
test.gis_point check status OK
diff --git a/mysql-test/suite/innodb_gis/r/rtree_concurrent_srch.result b/mysql-test/suite/innodb_gis/r/rtree_concurrent_srch.result
index 9c5db3e06aa..f5a337ecd03 100644
--- a/mysql-test/suite/innodb_gis/r/rtree_concurrent_srch.result
+++ b/mysql-test/suite/innodb_gis/r/rtree_concurrent_srch.result
@@ -234,7 +234,7 @@ start transaction;
set @g1 = ST_GeomFromText('Polygon((800 800, 800 1000, 1000 1000, 1000 800, 800 800))');
select count(*) from t1 where MBRwithin(t1.c2, @g1);
count(*)
-201
+199
connection b;
CALL insert_t1(1001, 2000);
set session transaction isolation level serializable;
diff --git a/mysql-test/suite/innodb_gis/r/rtree_split.result b/mysql-test/suite/innodb_gis/r/rtree_split.result
index 65a9ff3499f..518319ff3d6 100644
--- a/mysql-test/suite/innodb_gis/r/rtree_split.result
+++ b/mysql-test/suite/innodb_gis/r/rtree_split.result
@@ -79,7 +79,7 @@ count(*)
set @g1 = ST_GeomFromText('Polygon((2 2,2 800,800 800,800 2,2 2))');
select count(*) from t1 where MBRWithin(t1.c2, @g1);
count(*)
-65536
+57344
set @g1 = ST_GeomFromText('Polygon((0 0,0 100,100 100,100 0,0 0))');
select count(*) from t1 where MBRWithin(t1.c2, @g1);
count(*)
@@ -87,5 +87,5 @@ count(*)
set @g1 = ST_GeomFromText('Polygon((2 2,2 800,800 800,800 2,2 2))');
select count(*) from t1 where MBRWithin(t1.c2, @g1);
count(*)
-65536
+57344
drop table t1;