summaryrefslogtreecommitdiff
path: root/mysql-test/r/gis-rtree.result
diff options
context:
space:
mode:
authorAlexey Botchkov <holyfoot@askmonty.org>2012-05-29 09:59:25 +0500
committerAlexey Botchkov <holyfoot@askmonty.org>2012-05-29 09:59:25 +0500
commit662c51bad124b4290bcee52f049729c37e450858 (patch)
tree4015b71aac7121ccaa1e9a8958c01a83eb3a926b /mysql-test/r/gis-rtree.result
parentf50e4219ebcdaa1617cfd82e42991650a6f9ef29 (diff)
downloadmariadb-git-662c51bad124b4290bcee52f049729c37e450858.tar.gz
MDEV-294 SELECT WHERE ST_CONTAINS doesn't return all the records where ST_CONTAINS() is 1.
Optimizator fails using index with ST_Within(g, constant_poly). per-file comments: mysql-test/r/gis-rt-precise.result test result fixed. mysql-test/r/gis-rtree.result test result fixed. mysql-test/suite/maria/r/maria-gis-rtree-dynamic.result test result fixed. mysql-test/suite/maria/r/maria-gis-rtree-trans.result test result fixed. mysql-test/suite/maria/r/maria-gis-rtree.result test result fixed. storage/maria/ma_rt_index.c Use MBR_INTERSECT mode when optimizing the select WITH ST_Within. storage/myisam/rt_index.c Use MBR_INTERSECT mode when optimizing the select WITH ST_Within.
Diffstat (limited to 'mysql-test/r/gis-rtree.result')
-rw-r--r--mysql-test/r/gis-rtree.result14
1 files changed, 14 insertions, 0 deletions
diff --git a/mysql-test/r/gis-rtree.result b/mysql-test/r/gis-rtree.result
index a1c3f274ed3..26787366358 100644
--- a/mysql-test/r/gis-rtree.result
+++ b/mysql-test/r/gis-rtree.result
@@ -170,7 +170,17 @@ id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 range g g 34 NULL 8 Using where
SELECT fid, AsText(g) FROM t1 WHERE Within(g, GeomFromText('Polygon((140 140,160 140,160 160,140 160,140 140))'));
fid AsText(g)
+1 LINESTRING(150 150,150 150)
+3 LINESTRING(148 148,152 152)
+4 LINESTRING(147 147,153 153)
+5 LINESTRING(146 146,154 154)
+6 LINESTRING(145 145,155 155)
+7 LINESTRING(144 144,156 156)
+8 LINESTRING(143 143,157 157)
+9 LINESTRING(142 142,158 158)
+10 LINESTRING(141 141,159 159)
11 LINESTRING(140 140,160 160)
+2 LINESTRING(149 149,151 151)
DROP TABLE t1;
CREATE TABLE t2 (
fid INT NOT NULL AUTO_INCREMENT PRIMARY KEY,
@@ -295,6 +305,10 @@ id select_type table type possible_keys key key_len ref rows Extra
SELECT fid, AsText(g) FROM t2 WHERE Within(g,
GeomFromText('Polygon((40 40,60 40,60 60,40 60,40 40))'));
fid AsText(g)
+46 LINESTRING(51 41,60 50)
+56 LINESTRING(41 41,50 50)
+45 LINESTRING(51 51,60 60)
+55 LINESTRING(41 51,50 60)
DELETE FROM t2 WHERE Within(g, Envelope(GeometryFromWKB(Point(10 * 10 - 9, 10 * 10 - 9), Point(10 * 10, 10 * 10))));
SELECT count(*) FROM t2;
count(*)