summaryrefslogtreecommitdiff
path: root/mysql-test/r/gis-rtree.result
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2013-06-06 17:51:28 +0200
committerSergei Golubchik <sergii@pisem.net>2013-06-06 17:51:28 +0200
commit4749d40c635634e25e07d28ce1a04e9263bcc375 (patch)
treec5bb3287675cd8676d76c8ee42ef2d79cc599e25 /mysql-test/r/gis-rtree.result
parent1ff1cb10fc236010b5969058cab934c2b306c931 (diff)
parent33ef993773449cb3917665b188f6b6575d399bd0 (diff)
downloadmariadb-git-4749d40c635634e25e07d28ce1a04e9263bcc375.tar.gz
5.5 merge
Diffstat (limited to 'mysql-test/r/gis-rtree.result')
-rw-r--r--mysql-test/r/gis-rtree.result20
1 files changed, 20 insertions, 0 deletions
diff --git a/mysql-test/r/gis-rtree.result b/mysql-test/r/gis-rtree.result
index c394aec8851..22c30479125 100644
--- a/mysql-test/r/gis-rtree.result
+++ b/mysql-test/r/gis-rtree.result
@@ -1576,3 +1576,23 @@ a ASTEXT(b)
0 POINT(1 1)
DROP TABLE t1;
End of 5.1 tests
+CREATE TABLE t1 (
+l LINESTRING NOT NULL,
+SPATIAL KEY(l)
+) ENGINE = myisam;
+INSERT INTO t1 VALUES(GeomFromText('LINESTRING(0 0, 1 1)'));
+INSERT INTO t1 VALUES(GeomFromText('LINESTRING(1 1, 2 2)'));
+INSERT INTO t1 VALUES(GeomFromText('LINESTRING(2 2, 3 3)'));
+SELECT COUNT(*) FROM t1 IGNORE INDEX(l) WHERE MBRContains(l, GEOMFROMTEXT('POINT(0 0)'));
+COUNT(*)
+1
+SELECT COUNT(*) FROM t1 IGNORE INDEX(l) WHERE MBRWithin(GEOMFROMTEXT('POINT(0 0)'), l);
+COUNT(*)
+1
+SELECT COUNT(*) FROM t1 FORCE INDEX(l) WHERE MBRContains(l, GEOMFROMTEXT('POINT(0 0)'));
+COUNT(*)
+1
+SELECT COUNT(*) FROM t1 FORCE INDEX(l) WHERE MBRWithin(GEOMFROMTEXT('POINT(0 0)'), l);
+COUNT(*)
+1
+DROP TABLE t1;