~ubuntu-branches/ubuntu/precise/mysql-5.1/precise

« back to all changes in this revision

Viewing changes to mysql-test/t/gis.test

  • Committer: Bazaar Package Importer
  • Author(s): Norbert Tretkowski
  • Date: 2010-03-17 14:56:02 UTC
  • Revision ID: james.westby@ubuntu.com-20100317145602-x7e30l1b2sb5s6w6
Tags: upstream-5.1.45
ImportĀ upstreamĀ versionĀ 5.1.45

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
-- source include/have_geometry.inc
 
2
 
 
3
 
 
4
#
 
5
# Spatial objects
 
6
#
 
7
 
 
8
--disable_warnings
 
9
DROP TABLE IF EXISTS t1, gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gis_multi_polygon, gis_geometrycollection, gis_geometry;
 
10
--enable_warnings
 
11
 
 
12
CREATE TABLE gis_point  (fid INTEGER NOT NULL PRIMARY KEY, g POINT);
 
13
CREATE TABLE gis_line  (fid INTEGER NOT NULL PRIMARY KEY, g LINESTRING);
 
14
CREATE TABLE gis_polygon   (fid INTEGER NOT NULL PRIMARY KEY, g POLYGON);
 
15
CREATE TABLE gis_multi_point (fid INTEGER NOT NULL PRIMARY KEY, g MULTIPOINT);
 
16
CREATE TABLE gis_multi_line (fid INTEGER NOT NULL PRIMARY KEY, g MULTILINESTRING);
 
17
CREATE TABLE gis_multi_polygon  (fid INTEGER NOT NULL PRIMARY KEY, g MULTIPOLYGON);
 
18
CREATE TABLE gis_geometrycollection  (fid INTEGER NOT NULL PRIMARY KEY, g GEOMETRYCOLLECTION);
 
19
CREATE TABLE gis_geometry (fid INTEGER NOT NULL PRIMARY KEY, g GEOMETRY);
 
20
 
 
21
SHOW FIELDS FROM gis_point;
 
22
SHOW FIELDS FROM gis_line;
 
23
SHOW FIELDS FROM gis_polygon;
 
24
SHOW FIELDS FROM gis_multi_point;
 
25
SHOW FIELDS FROM gis_multi_line;
 
26
SHOW FIELDS FROM gis_multi_polygon;
 
27
SHOW FIELDS FROM gis_geometrycollection;
 
28
SHOW FIELDS FROM gis_geometry;
 
29
 
 
30
 
 
31
INSERT INTO gis_point VALUES 
 
32
(101, PointFromText('POINT(10 10)')),
 
33
(102, PointFromText('POINT(20 10)')),
 
34
(103, PointFromText('POINT(20 20)')),
 
35
(104, PointFromWKB(AsWKB(PointFromText('POINT(10 20)'))));
 
36
 
 
37
INSERT INTO gis_line VALUES
 
38
(105, LineFromText('LINESTRING(0 0,0 10,10 0)')),
 
39
(106, LineStringFromText('LINESTRING(10 10,20 10,20 20,10 20,10 10)')),
 
40
(107, LineStringFromWKB(AsWKB(LineString(Point(10, 10), Point(40, 10)))));
 
41
 
 
42
INSERT INTO gis_polygon VALUES
 
43
(108, PolygonFromText('POLYGON((10 10,20 10,20 20,10 20,10 10))')),
 
44
(109, PolyFromText('POLYGON((0 0,50 0,50 50,0 50,0 0), (10 10,20 10,20 20,10 20,10 10))')),
 
45
(110, PolyFromWKB(AsWKB(Polygon(LineString(Point(0, 0), Point(30, 0), Point(30, 30), Point(0, 0))))));
 
46
 
 
47
INSERT INTO gis_multi_point VALUES
 
48
(111, MultiPointFromText('MULTIPOINT(0 0,10 10,10 20,20 20)')),
 
49
(112, MPointFromText('MULTIPOINT(1 1,11 11,11 21,21 21)')),
 
50
(113, MPointFromWKB(AsWKB(MultiPoint(Point(3, 6), Point(4, 10)))));
 
51
 
 
52
INSERT INTO gis_multi_line VALUES
 
53
(114, MultiLineStringFromText('MULTILINESTRING((10 48,10 21,10 0),(16 0,16 23,16 48))')),
 
54
(115, MLineFromText('MULTILINESTRING((10 48,10 21,10 0))')),
 
55
(116, MLineFromWKB(AsWKB(MultiLineString(LineString(Point(1, 2), Point(3, 5)), LineString(Point(2, 5), Point(5, 8), Point(21, 7))))));
 
56
 
 
57
 
 
58
INSERT INTO gis_multi_polygon VALUES
 
59
(117, MultiPolygonFromText('MULTIPOLYGON(((28 26,28 0,84 0,84 42,28 26),(52 18,66 23,73 9,48 6,52 18)),((59 18,67 18,67 13,59 13,59 18)))')),
 
60
(118, MPolyFromText('MULTIPOLYGON(((28 26,28 0,84 0,84 42,28 26),(52 18,66 23,73 9,48 6,52 18)),((59 18,67 18,67 13,59 13,59 18)))')),
 
61
(119, MPolyFromWKB(AsWKB(MultiPolygon(Polygon(LineString(Point(0, 3), Point(3, 3), Point(3, 0), Point(0, 3)))))));
 
62
 
 
63
INSERT INTO gis_geometrycollection VALUES
 
64
(120, GeomCollFromText('GEOMETRYCOLLECTION(POINT(0 0), LINESTRING(0 0,10 10))')),
 
65
(121, GeometryFromWKB(AsWKB(GeometryCollection(Point(44, 6), LineString(Point(3, 6), Point(7, 9))))));
 
66
 
 
67
INSERT into gis_geometry SELECT * FROM gis_point;
 
68
INSERT into gis_geometry SELECT * FROM gis_line;
 
69
INSERT into gis_geometry SELECT * FROM gis_polygon;
 
70
INSERT into gis_geometry SELECT * FROM gis_multi_point;
 
71
INSERT into gis_geometry SELECT * FROM gis_multi_line;
 
72
INSERT into gis_geometry SELECT * FROM gis_multi_polygon;
 
73
INSERT into gis_geometry SELECT * FROM gis_geometrycollection;
 
74
 
 
75
SELECT fid, AsText(g) FROM gis_point;
 
76
SELECT fid, AsText(g) FROM gis_line;
 
77
SELECT fid, AsText(g) FROM gis_polygon;
 
78
SELECT fid, AsText(g) FROM gis_multi_point;
 
79
SELECT fid, AsText(g) FROM gis_multi_line;
 
80
SELECT fid, AsText(g) FROM gis_multi_polygon;
 
81
SELECT fid, AsText(g) FROM gis_geometrycollection;
 
82
SELECT fid, AsText(g) FROM gis_geometry;
 
83
 
 
84
SELECT fid, Dimension(g) FROM gis_geometry;
 
85
SELECT fid, GeometryType(g) FROM gis_geometry;
 
86
SELECT fid, IsEmpty(g) FROM gis_geometry;
 
87
SELECT fid, AsText(Envelope(g)) FROM gis_geometry;
 
88
explain extended select Dimension(g), GeometryType(g), IsEmpty(g), AsText(Envelope(g)) from gis_geometry;
 
89
 
 
90
SELECT fid, X(g) FROM gis_point;
 
91
SELECT fid, Y(g) FROM gis_point;
 
92
explain extended select X(g),Y(g) FROM gis_point;
 
93
 
 
94
SELECT fid, AsText(StartPoint(g)) FROM gis_line;
 
95
SELECT fid, AsText(EndPoint(g)) FROM gis_line;
 
96
SELECT fid, GLength(g) FROM gis_line;
 
97
SELECT fid, NumPoints(g) FROM gis_line;
 
98
SELECT fid, AsText(PointN(g, 2)) FROM gis_line;
 
99
SELECT fid, IsClosed(g) FROM gis_line;
 
100
explain extended select AsText(StartPoint(g)),AsText(EndPoint(g)),GLength(g),NumPoints(g),AsText(PointN(g, 2)),IsClosed(g) FROM gis_line;
 
101
 
 
102
SELECT fid, AsText(Centroid(g)) FROM gis_polygon;
 
103
SELECT fid, Area(g) FROM gis_polygon;
 
104
SELECT fid, AsText(ExteriorRing(g)) FROM gis_polygon;
 
105
SELECT fid, NumInteriorRings(g) FROM gis_polygon;
 
106
SELECT fid, AsText(InteriorRingN(g, 1)) FROM gis_polygon;
 
107
explain extended select AsText(Centroid(g)),Area(g),AsText(ExteriorRing(g)),NumInteriorRings(g),AsText(InteriorRingN(g, 1)) FROM gis_polygon;
 
108
 
 
109
SELECT fid, IsClosed(g) FROM gis_multi_line;
 
110
 
 
111
SELECT fid, AsText(Centroid(g)) FROM gis_multi_polygon;
 
112
SELECT fid, Area(g) FROM gis_multi_polygon;
 
113
 
 
114
SELECT fid, NumGeometries(g) from gis_multi_point;
 
115
SELECT fid, NumGeometries(g) from gis_multi_line;
 
116
SELECT fid, NumGeometries(g) from gis_multi_polygon;
 
117
SELECT fid, NumGeometries(g) from gis_geometrycollection;
 
118
explain extended SELECT fid, NumGeometries(g) from gis_multi_point;
 
119
 
 
120
SELECT fid, AsText(GeometryN(g, 2)) from gis_multi_point;
 
121
SELECT fid, AsText(GeometryN(g, 2)) from gis_multi_line;
 
122
SELECT fid, AsText(GeometryN(g, 2)) from gis_multi_polygon;
 
123
SELECT fid, AsText(GeometryN(g, 2)) from gis_geometrycollection;
 
124
SELECT fid, AsText(GeometryN(g, 1)) from gis_geometrycollection;
 
125
explain extended SELECT fid, AsText(GeometryN(g, 2)) from gis_multi_point;
 
126
 
 
127
SELECT g1.fid as first, g2.fid as second,
 
128
Within(g1.g, g2.g) as w, Contains(g1.g, g2.g) as c, Overlaps(g1.g, g2.g) as o,
 
129
Equals(g1.g, g2.g) as e, Disjoint(g1.g, g2.g) as d, Touches(g1.g, g2.g) as t,
 
130
Intersects(g1.g, g2.g) as i, Crosses(g1.g, g2.g) as r
 
131
FROM gis_geometrycollection g1, gis_geometrycollection g2 ORDER BY first, second;
 
132
explain extended SELECT g1.fid as first, g2.fid as second,
 
133
Within(g1.g, g2.g) as w, Contains(g1.g, g2.g) as c, Overlaps(g1.g, g2.g) as o,
 
134
Equals(g1.g, g2.g) as e, Disjoint(g1.g, g2.g) as d, Touches(g1.g, g2.g) as t,
 
135
Intersects(g1.g, g2.g) as i, Crosses(g1.g, g2.g) as r
 
136
FROM gis_geometrycollection g1, gis_geometrycollection g2 ORDER BY first, second;
 
137
 
 
138
DROP TABLE gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gis_multi_polygon, gis_geometrycollection, gis_geometry;
 
139
 
 
140
#
 
141
# Check that ALTER TABLE doesn't loose geometry type
 
142
#
 
143
CREATE TABLE t1 (
 
144
  gp  point,
 
145
  ln  linestring,
 
146
  pg  polygon,
 
147
  mp  multipoint,
 
148
  mln multilinestring,
 
149
  mpg multipolygon,
 
150
  gc  geometrycollection,
 
151
  gm  geometry
 
152
);
 
153
 
 
154
SHOW FIELDS FROM t1;
 
155
ALTER TABLE t1 ADD fid INT NOT NULL;
 
156
SHOW FIELDS FROM t1;
 
157
DROP TABLE t1;
 
158
 
 
159
SELECT AsText(GeometryFromWKB(AsWKB(GeometryFromText('POINT(1 4)'))));
 
160
explain extended SELECT AsText(GeometryFromWKB(AsWKB(GeometryFromText('POINT(1 4)'))));
 
161
explain extended SELECT AsText(GeometryFromWKB(AsWKB(PointFromText('POINT(1 4)'))));
 
162
SELECT SRID(GeomFromText('LineString(1 1,2 2)',101));
 
163
explain extended SELECT SRID(GeomFromText('LineString(1 1,2 2)',101));
 
164
#select issimple(MultiPoint(Point(3, 6), Point(4, 10))), issimple(Point(3, 6)),issimple(PolygonFromText('POLYGON((10 10,20 10,20 20,10 20,10 10))')),issimple(GeometryFromText('POINT(1 4)')), issimple(AsWKB(GeometryFromText('POINT(1 4)')));
 
165
explain extended select issimple(MultiPoint(Point(3, 6), Point(4, 10))), issimple(Point(3, 6));
 
166
 
 
167
create table t1 (a geometry not null);
 
168
insert into t1 values (GeomFromText('Point(1 2)'));
 
169
-- error 1416
 
170
insert into t1 values ('Garbage');
 
171
-- error 1416
 
172
insert IGNORE into t1 values ('Garbage');
 
173
alter table t1 add spatial index(a);
 
174
 
 
175
drop table t1;
 
176
 
 
177
#
 
178
# Bug #5219: problem with range optimizer
 
179
#
 
180
 
 
181
create table t1(a geometry not null, spatial index(a));
 
182
insert into t1 values
 
183
(GeomFromText('POINT(1 1)')), (GeomFromText('POINT(3 3)')), 
 
184
(GeomFromText('POINT(4 4)')), (GeomFromText('POINT(6 6)'));
 
185
select AsText(a) from t1 where
 
186
  MBRContains(GeomFromText('Polygon((0 0, 0 2, 2 2, 2 0, 0 0))'), a)
 
187
  or
 
188
  MBRContains(GeomFromText('Polygon((2 2, 2 5, 5 5, 5 2, 2 2))'), a);
 
189
select AsText(a) from t1 where
 
190
  MBRContains(GeomFromText('Polygon((0 0, 0 2, 2 2, 2 0, 0 0))'), a)
 
191
  and
 
192
  MBRContains(GeomFromText('Polygon((0 0, 0 7, 7 7, 7 0, 0 0))'), a);
 
193
drop table t1;
 
194
 
 
195
CREATE TABLE t1 (Coordinates POINT NOT NULL, SPATIAL INDEX(Coordinates)); 
 
196
INSERT INTO t1 VALUES(GeomFromText('POINT(383293632 1754448)')); 
 
197
INSERT INTO t1 VALUES(GeomFromText('POINT(564952612 157516260)')); 
 
198
INSERT INTO t1 VALUES(GeomFromText('POINT(903994614 180726515)')); 
 
199
INSERT INTO t1 VALUES(GeomFromText('POINT(98128178 141127631)')); 
 
200
INSERT INTO t1 VALUES(GeomFromText('POINT(862547902 799334546)')); 
 
201
INSERT INTO t1 VALUES(GeomFromText('POINT(341989013 850270906)')); 
 
202
INSERT INTO t1 VALUES(GeomFromText('POINT(803302376 93039099)')); 
 
203
INSERT INTO t1 VALUES(GeomFromText('POINT(857439153 817431356)')); 
 
204
INSERT INTO t1 VALUES(GeomFromText('POINT(319757546 343162742)')); 
 
205
INSERT INTO t1 VALUES(GeomFromText('POINT(826341972 717484432)')); 
 
206
INSERT INTO t1 VALUES(GeomFromText('POINT(305066789 201736238)')); 
 
207
INSERT INTO t1 VALUES(GeomFromText('POINT(626068992 616241497)')); 
 
208
INSERT INTO t1 VALUES(GeomFromText('POINT(55789424 755830108)')); 
 
209
INSERT INTO t1 VALUES(GeomFromText('POINT(802874458 312435220)')); 
 
210
INSERT INTO t1 VALUES(GeomFromText('POINT(153795660 551723671)')); 
 
211
INSERT INTO t1 VALUES(GeomFromText('POINT(242207428 537089292)')); 
 
212
INSERT INTO t1 VALUES(GeomFromText('POINT(553478119 807160039)')); 
 
213
INSERT INTO t1 VALUES(GeomFromText('POINT(694605552 457472733)')); 
 
214
INSERT INTO t1 VALUES(GeomFromText('POINT(987886554 792733729)')); 
 
215
INSERT INTO t1 VALUES(GeomFromText('POINT(598600363 850434457)')); 
 
216
INSERT INTO t1 VALUES(GeomFromText('POINT(592068275 940589376)')); 
 
217
INSERT INTO t1 VALUES(GeomFromText('POINT(700705362 395370650)')); 
 
218
INSERT INTO t1 VALUES(GeomFromText('POINT(33628474 558144514)')); 
 
219
INSERT INTO t1 VALUES(GeomFromText('POINT(212802006 353386020)')); 
 
220
INSERT INTO t1 VALUES(GeomFromText('POINT(901307256 39143977)')); 
 
221
INSERT INTO t1 VALUES(GeomFromText('POINT(70870451 206374045)')); 
 
222
INSERT INTO t1 VALUES(GeomFromText('POINT(240880214 696939443)')); 
 
223
INSERT INTO t1 VALUES(GeomFromText('POINT(822615542 296669638)')); 
 
224
INSERT INTO t1 VALUES(GeomFromText('POINT(452769551 625489999)')); 
 
225
INSERT INTO t1 VALUES(GeomFromText('POINT(609104858 606565210)')); 
 
226
INSERT INTO t1 VALUES(GeomFromText('POINT(177213669 851312285)')); 
 
227
INSERT INTO t1 VALUES(GeomFromText('POINT(143654501 730691787)')); 
 
228
INSERT INTO t1 VALUES(GeomFromText('POINT(658472325 838260052)')); 
 
229
INSERT INTO t1 VALUES(GeomFromText('POINT(188164520 646358878)')); 
 
230
INSERT INTO t1 VALUES(GeomFromText('POINT(630993781 786764883)')); 
 
231
INSERT INTO t1 VALUES(GeomFromText('POINT(496793334 223062055)')); 
 
232
INSERT INTO t1 VALUES(GeomFromText('POINT(727354258 197498696)')); 
 
233
INSERT INTO t1 VALUES(GeomFromText('POINT(618432704 760982731)')); 
 
234
INSERT INTO t1 VALUES(GeomFromText('POINT(755643210 831234710)')); 
 
235
INSERT INTO t1 VALUES(GeomFromText('POINT(114368751 656950466)')); 
 
236
INSERT INTO t1 VALUES(GeomFromText('POINT(870378686 185239202)')); 
 
237
INSERT INTO t1 VALUES(GeomFromText('POINT(863324511 111258900)')); 
 
238
INSERT INTO t1 VALUES(GeomFromText('POINT(882178645 685940052)')); 
 
239
INSERT INTO t1 VALUES(GeomFromText('POINT(407928538 334948195)')); 
 
240
INSERT INTO t1 VALUES(GeomFromText('POINT(311430051 17033395)')); 
 
241
INSERT INTO t1 VALUES(GeomFromText('POINT(941513405 488643719)')); 
 
242
INSERT INTO t1 VALUES(GeomFromText('POINT(868345680 85167906)')); 
 
243
INSERT INTO t1 VALUES(GeomFromText('POINT(219335507 526818004)')); 
 
244
INSERT INTO t1 VALUES(GeomFromText('POINT(923427958 407500026)')); 
 
245
INSERT INTO t1 VALUES(GeomFromText('POINT(173176882 554421738)')); 
 
246
INSERT INTO t1 VALUES(GeomFromText('POINT(194264908 669970217)')); 
 
247
INSERT INTO t1 VALUES(GeomFromText('POINT(777483793 921619165)')); 
 
248
INSERT INTO t1 VALUES(GeomFromText('POINT(867468912 395916497)')); 
 
249
INSERT INTO t1 VALUES(GeomFromText('POINT(682601897 623112122)')); 
 
250
INSERT INTO t1 VALUES(GeomFromText('POINT(227151206 796970647)')); 
 
251
INSERT INTO t1 VALUES(GeomFromText('POINT(280062588 97529892)')); 
 
252
INSERT INTO t1 VALUES(GeomFromText('POINT(982209849 143387099)')); 
 
253
INSERT INTO t1 VALUES(GeomFromText('POINT(208788792 864388493)')); 
 
254
INSERT INTO t1 VALUES(GeomFromText('POINT(829327151 616717329)')); 
 
255
INSERT INTO t1 VALUES(GeomFromText('POINT(199336688 140757201)')); 
 
256
INSERT INTO t1 VALUES(GeomFromText('POINT(633750724 140850093)')); 
 
257
INSERT INTO t1 VALUES(GeomFromText('POINT(629400920 502096404)')); 
 
258
INSERT INTO t1 VALUES(GeomFromText('POINT(226017998 848736426)')); 
 
259
INSERT INTO t1 VALUES(GeomFromText('POINT(28914408 149445955)')); 
 
260
INSERT INTO t1 VALUES(GeomFromText('POINT(256236452 202091290)')); 
 
261
INSERT INTO t1 VALUES(GeomFromText('POINT(703867693 450501360)')); 
 
262
INSERT INTO t1 VALUES(GeomFromText('POINT(872061506 481351486)')); 
 
263
INSERT INTO t1 VALUES(GeomFromText('POINT(372120524 739530418)')); 
 
264
INSERT INTO t1 VALUES(GeomFromText('POINT(877267982 54722420)')); 
 
265
INSERT INTO t1 VALUES(GeomFromText('POINT(362642540 104419188)')); 
 
266
INSERT INTO t1 VALUES(GeomFromText('POINT(851693067 642705127)')); 
 
267
INSERT INTO t1 VALUES(GeomFromText('POINT(201949080 833902916)')); 
 
268
INSERT INTO t1 VALUES(GeomFromText('POINT(786092225 410737872)')); 
 
269
INSERT INTO t1 VALUES(GeomFromText('POINT(698291409 615419376)')); 
 
270
INSERT INTO t1 VALUES(GeomFromText('POINT(27455201 897628096)')); 
 
271
INSERT INTO t1 VALUES(GeomFromText('POINT(756176576 661205925)')); 
 
272
INSERT INTO t1 VALUES(GeomFromText('POINT(38478189 385577496)')); 
 
273
INSERT INTO t1 VALUES(GeomFromText('POINT(163302328 264496186)')); 
 
274
INSERT INTO t1 VALUES(GeomFromText('POINT(234313922 192216735)')); 
 
275
INSERT INTO t1 VALUES(GeomFromText('POINT(413942141 490550373)')); 
 
276
INSERT INTO t1 VALUES(GeomFromText('POINT(394308025 117809834)')); 
 
277
INSERT INTO t1 VALUES(GeomFromText('POINT(941051732 266369530)')); 
 
278
INSERT INTO t1 VALUES(GeomFromText('POINT(599161319 313172256)')); 
 
279
INSERT INTO t1 VALUES(GeomFromText('POINT(5899948 476429301)')); 
 
280
INSERT INTO t1 VALUES(GeomFromText('POINT(367894677 368542487)')); 
 
281
INSERT INTO t1 VALUES(GeomFromText('POINT(580848489 219587743)')); 
 
282
INSERT INTO t1 VALUES(GeomFromText('POINT(11247614 782797569)')); 
 
283
drop table t1;
 
284
 
 
285
create table t1 select GeomFromWKB(POINT(1,3));
 
286
show create table t1;
 
287
drop table t1;
 
288
 
 
289
CREATE TABLE `t1` (`object_id` bigint(20) unsigned NOT NULL default '0', `geo`
 
290
geometry NOT NULL default '') ENGINE=MyISAM ;
 
291
 
 
292
insert into t1 values ('85984',GeomFromText('MULTIPOLYGON(((-115.006363
 
293
36.305435,-114.992394 36.305202,-114.991219 36.305975,-114.991163
 
294
36.306845,-114.989432 36.309452,-114.978275 36.312642,-114.977363
 
295
36.311978,-114.975327 36.312344,-114.96502 36.31597,-114.963364
 
296
36.313629,-114.961723 36.313721,-114.956398 36.316057,-114.951882
 
297
36.320979,-114.947073 36.323475,-114.945207 36.326451,-114.945207
 
298
36.326451,-114.944132 36.326061,-114.94003 36.326588,-114.924017
 
299
36.334484,-114.923281 36.334146,-114.92564 36.331504,-114.94072
 
300
36.319282,-114.945348 36.314812,-114.948091 36.314762,-114.951755
 
301
36.316211,-114.952446 36.313883,-114.952644 36.309488,-114.944725
 
302
36.313083,-114.93706 36.32043,-114.932478 36.323497,-114.924556
 
303
36.327708,-114.922608 36.329715,-114.92009 36.328695,-114.912105
 
304
36.323566,-114.901647 36.317952,-114.897436 36.313968,-114.895344
 
305
36.309573,-114.891699 36.304398,-114.890569 36.303551,-114.886356
 
306
36.302702,-114.885141 36.301351,-114.885709 36.297391,-114.892499
 
307
36.290893,-114.902142 36.288974,-114.904941 36.288838,-114.905308
 
308
36.289845,-114.906325 36.290395,-114.909916 36.289549,-114.914527
 
309
36.287535,-114.918797 36.284423,-114.922982 36.279731,-114.924113
 
310
36.277282,-114.924057 36.275817,-114.927733 36.27053,-114.929354
 
311
36.269029,-114.929354 36.269029,-114.950856 36.268715,-114.950768
 
312
36.264324,-114.960206 36.264293,-114.960301 36.268943,-115.006662
 
313
36.268929,-115.008583 36.265619,-115.00665 36.264247,-115.006659
 
314
36.246873,-115.006659 36.246873,-115.006838 36.247697,-115.010764
 
315
36.247774,-115.015609 36.25113,-115.015765 36.254505,-115.029517
 
316
36.254619,-115.038573 36.249317,-115.038573 36.249317,-115.023403
 
317
36.25841,-115.023873 36.258994,-115.031845 36.259829,-115.03183
 
318
36.261053,-115.025561 36.261095,-115.036417 36.274632,-115.033729
 
319
36.276041,-115.032217 36.274851,-115.029845 36.273959,-115.029934
 
320
36.274966,-115.025763 36.274896,-115.025406 36.281044,-115.028731
 
321
36.284471,-115.036497 36.290377,-115.042071 36.291039,-115.026759
 
322
36.298478,-115.008995 36.301966,-115.006363 36.305435),(-115.079835
 
323
36.244369,-115.079735 36.260186,-115.076435 36.262369,-115.069758
 
324
36.265,-115.070235 36.268757,-115.064542 36.268655,-115.061843
 
325
36.269857,-115.062676 36.270693,-115.06305 36.272344,-115.059051
 
326
36.281023,-115.05918 36.283008,-115.060591 36.285246,-115.061913
 
327
36.290022,-115.062499 36.306353,-115.062499 36.306353,-115.060918
 
328
36.30642,-115.06112 36.289779,-115.05713 36.2825,-115.057314
 
329
36.279446,-115.060779 36.274659,-115.061366 36.27209,-115.057858
 
330
36.26557,-115.055805 36.262883,-115.054688 36.262874,-115.047335
 
331
36.25037,-115.044234 36.24637,-115.052434 36.24047,-115.061734
 
332
36.23507,-115.061934 36.22677,-115.061934 36.22677,-115.061491
 
333
36.225267,-115.062024 36.218194,-115.060134 36.218278,-115.060133
 
334
36.210771,-115.057833 36.210771,-115.057433 36.196271,-115.062233
 
335
36.196271,-115.062233 36.190371,-115.062233 36.190371,-115.065533
 
336
36.190371,-115.071333 36.188571,-115.098331 36.188275,-115.098331
 
337
36.188275,-115.098435 36.237569,-115.097535 36.240369,-115.097535
 
338
36.240369,-115.093235 36.240369,-115.089135 36.240469,-115.083135
 
339
36.240569,-115.083135 36.240569,-115.079835
 
340
36.244369)))')),('85998',GeomFromText('MULTIPOLYGON(((-115.333107
 
341
36.264587,-115.333168 36.280638,-115.333168 36.280638,-115.32226
 
342
36.280643,-115.322538 36.274311,-115.327222 36.274258,-115.32733
 
343
36.263026,-115.330675 36.262984,-115.332132 36.264673,-115.333107
 
344
36.264587),(-115.247239 36.247066,-115.247438 36.218267,-115.247438
 
345
36.218267,-115.278525 36.219263,-115.278525 36.219263,-115.301545
 
346
36.219559,-115.332748 36.219197,-115.332757 36.220041,-115.332757
 
347
36.220041,-115.332895 36.233514,-115.349023 36.233479,-115.351489
 
348
36.234475,-115.353681 36.237021,-115.357106 36.239789,-115.36519
 
349
36.243331,-115.368156 36.243487,-115.367389 36.244902,-115.364553
 
350
36.246014,-115.359219 36.24616,-115.356186 36.248025,-115.353347
 
351
36.248004,-115.350813 36.249507,-115.339673 36.25387,-115.333069
 
352
36.255018,-115.333069 36.255018,-115.333042 36.247767,-115.279039
 
353
36.248666,-115.263639 36.247466,-115.263839 36.252766,-115.261439
 
354
36.252666,-115.261439 36.247366,-115.247239 36.247066)))'));
 
355
 
 
356
select object_id, geometrytype(geo), ISSIMPLE(GEO), ASTEXT(centroid(geo)) from
 
357
t1 where object_id=85998;
 
358
 
 
359
# Expected result is 36.3310176346905, but IA64 returns 36.3310176346904
 
360
# due to fused multiply-add instructions.
 
361
--replace_result 36.3310176346904 36.3310176346905
 
362
select object_id, geometrytype(geo), ISSIMPLE(GEO), ASTEXT(centroid(geo)) from
 
363
t1 where object_id=85984;
 
364
 
 
365
drop table t1;
 
366
 
 
367
create table t1 (fl geometry not null);
 
368
--error 1416
 
369
insert into t1 values (1);
 
370
--error 1416
 
371
insert into t1 values (1.11);
 
372
--error 1416
 
373
insert into t1 values ("qwerty");
 
374
--error 1048
 
375
insert into t1 values (pointfromtext('point(1,1)'));
 
376
 
 
377
drop table t1;
 
378
 
 
379
select (asWKT(geomfromwkb((0x000000000140240000000000004024000000000000))));
 
380
select (asWKT(geomfromwkb((0x010100000000000000000024400000000000002440))));
 
381
 
 
382
--enable_metadata
 
383
create table t1 (g GEOMETRY);
 
384
select * from t1;
 
385
select asbinary(g) from t1;
 
386
--disable_metadata
 
387
drop table t1;
 
388
 
 
389
create table t1 (a TEXT, b GEOMETRY NOT NULL, SPATIAL KEY(b));
 
390
alter table t1 disable keys;
 
391
--error 1263
 
392
load data infile '../../std_data/bad_gis_data.dat' into table t1;
 
393
alter table t1 enable keys;
 
394
drop table t1;
 
395
 
 
396
#
 
397
# Bug #26038: is null and bad data
 
398
#
 
399
 
 
400
create table t1 (a int, b blob);
 
401
insert into t1 values (1, ''), (2, NULL), (3, '1');
 
402
select * from t1;
 
403
 
 
404
select
 
405
  geometryfromtext(b) IS NULL, geometryfromwkb(b) IS NULL, astext(b) IS NULL, 
 
406
  aswkb(b) IS NULL, geometrytype(b) IS NULL, centroid(b) IS NULL,
 
407
  envelope(b) IS NULL, startpoint(b) IS NULL, endpoint(b) IS NULL,
 
408
  exteriorring(b) IS NULL, pointn(b, 1) IS NULL, geometryn(b, 1) IS NULL,
 
409
  interiorringn(b, 1) IS NULL, multipoint(b) IS NULL, isempty(b) IS NULL,
 
410
  issimple(b) IS NULL, isclosed(b) IS NULL, dimension(b) IS NULL,
 
411
  numgeometries(b) IS NULL, numinteriorrings(b) IS NULL, numpoints(b) IS NULL,
 
412
  area(b) IS NULL, glength(b) IS NULL, srid(b) IS NULL, x(b) IS NULL, 
 
413
  y(b) IS NULL
 
414
from t1;
 
415
 
 
416
select 
 
417
  within(b, b) IS NULL, contains(b, b) IS NULL, overlaps(b, b) IS NULL, 
 
418
  equals(b, b) IS NULL, disjoint(b, b) IS NULL, touches(b, b) IS NULL, 
 
419
  intersects(b, b) IS NULL, crosses(b, b) IS NULL
 
420
from t1;
 
421
 
 
422
select 
 
423
  point(b, b) IS NULL, linestring(b) IS NULL, polygon(b) IS NULL, multipoint(b) IS NULL, 
 
424
  multilinestring(b) IS NULL, multipolygon(b) IS NULL, 
 
425
  geometrycollection(b) IS NULL
 
426
from t1;
 
427
 
 
428
drop table t1;
 
429
 
 
430
#
 
431
# Bug #27164: Crash when mixing InnoDB and MyISAM Geospatial tables
 
432
#
 
433
CREATE TABLE t1(a POINT) ENGINE=MyISAM;
 
434
INSERT INTO t1 VALUES (NULL);
 
435
SELECT * FROM t1;
 
436
DROP TABLE t1;
 
437
 
 
438
#
 
439
# Bug #30955 geomfromtext() crasher
 
440
#
 
441
CREATE TABLE `t1` ( `col9` set('a'), `col89` date);
 
442
INSERT INTO `t1` VALUES ('','0000-00-00');
 
443
select geomfromtext(col9,col89) as a from t1;
 
444
DROP TABLE t1;
 
445
 
 
446
#
 
447
# Bug #31158 Spatial, Union, LONGBLOB vs BLOB bug (crops data) 
 
448
#
 
449
 
 
450
CREATE TABLE t1 (
 
451
  geomdata polygon NOT NULL,
 
452
  SPATIAL KEY index_geom (geomdata)
 
453
) ENGINE=MyISAM DEFAULT CHARSET=latin2 DELAY_KEY_WRITE=1 ROW_FORMAT=FIXED;
 
454
 
 
455
CREATE TABLE t2 (
 
456
  geomdata polygon NOT NULL,
 
457
  SPATIAL KEY index_geom (geomdata)
 
458
) ENGINE=MyISAM DEFAULT CHARSET=latin2 DELAY_KEY_WRITE=1 ROW_FORMAT=FIXED;
 
459
 
 
460
CREATE TABLE t3
 
461
select 
 
462
    aswkb(ws.geomdata) AS geomdatawkb 
 
463
  from 
 
464
    t1 ws
 
465
union 
 
466
  select 
 
467
    aswkb(ws.geomdata) AS geomdatawkb 
 
468
  from 
 
469
    t2 ws;
 
470
 
 
471
describe t3;
 
472
 
 
473
drop table t1;
 
474
drop table t2;
 
475
drop table t3;
 
476
 
 
477
#
 
478
# Bug #30284 spatial key corruption 
 
479
#
 
480
 
 
481
create table t1(col1 geometry default null,col15 geometrycollection not
 
482
null,spatial index(col15),index(col1(15)))engine=myisam;
 
483
insert into t1 set col15 = GeomFromText('POINT(6 5)');
 
484
insert into t1 set col15 = GeomFromText('POINT(6 5)');
 
485
check table t1 extended;
 
486
drop table t1;
 
487
 
 
488
--echo End of 4.1 tests
 
489
 
 
490
#
 
491
# Bug #12281 (Geometry: crash in trigger)
 
492
#
 
493
 
 
494
create table t1 (s1 geometry not null,s2 char(100));
 
495
create trigger t1_bu before update on t1 for each row set new.s1 = null;
 
496
--error 1048
 
497
insert into t1 values (null,null);
 
498
drop table t1;
 
499
 
 
500
#
 
501
# Bug #10499 (function creation with GEOMETRY datatype)
 
502
#
 
503
--disable_warnings
 
504
drop procedure if exists fn3;
 
505
--enable_warnings
 
506
create function fn3 () returns point deterministic return GeomFromText("point(1 1)"); 
 
507
show create function fn3;
 
508
select astext(fn3());
 
509
drop function fn3;
 
510
 
 
511
#
 
512
# Bug #12267 (primary key over GIS)
 
513
#
 
514
create table t1(pt POINT);
 
515
alter table t1 add primary key pti(pt);
 
516
drop table t1;
 
517
create table t1(pt GEOMETRY);
 
518
--error 1170
 
519
alter table t1 add primary key pti(pt);
 
520
alter table t1 add primary key pti(pt(20));
 
521
drop table t1;
 
522
 
 
523
 
 
524
create table t1 select GeomFromText('point(1 1)');
 
525
desc t1;
 
526
drop table t1;
 
527
 
 
528
#
 
529
# Bug #20691 (DEFAULT over NOT NULL field)
 
530
#
 
531
create table t1 (g geometry not null);
 
532
--error ER_CANT_CREATE_GEOMETRY_OBJECT
 
533
insert into t1 values(default);
 
534
drop table t1;
 
535
 
 
536
#
 
537
# Bug #27300: create view with geometry functions lost columns types 
 
538
#
 
539
CREATE TABLE t1 (a GEOMETRY);
 
540
CREATE VIEW v1 AS SELECT GeomFromwkb(ASBINARY(a)) FROM t1;
 
541
CREATE VIEW v2 AS SELECT a FROM t1;
 
542
DESCRIBE v1;
 
543
DESCRIBE v2;
 
544
 
 
545
DROP VIEW v1,v2;
 
546
DROP TABLE t1;
 
547
 
 
548
#
 
549
# Bug#24563: MBROverlaps does not seem to function propertly
 
550
# Bug#54888: MBROverlaps missing in 5.1?
 
551
#
 
552
 
 
553
# Test all MBR* functions and their non-MBR-prefixed aliases,
 
554
# using shifted squares to verify the spatial relations.
 
555
 
 
556
create table t1 (name VARCHAR(100), square GEOMETRY);
 
557
 
 
558
INSERT INTO t1 VALUES("center", GeomFromText('POLYGON (( 0 0, 0 2, 2 2, 2 0, 0 0))'));
 
559
 
 
560
INSERT INTO t1 VALUES("small",  GeomFromText('POLYGON (( 0 0, 0 1, 1 1, 1 0, 0 0))'));
 
561
INSERT INTO t1 VALUES("big",    GeomFromText('POLYGON (( 0 0, 0 3, 3 3, 3 0, 0 0))'));
 
562
 
 
563
INSERT INTO t1 VALUES("up",     GeomFromText('POLYGON (( 0 1, 0 3, 2 3, 2 1, 0 1))'));
 
564
INSERT INTO t1 VALUES("up2",    GeomFromText('POLYGON (( 0 2, 0 4, 2 4, 2 2, 0 2))'));
 
565
INSERT INTO t1 VALUES("up3",    GeomFromText('POLYGON (( 0 3, 0 5, 2 5, 2 3, 0 3))'));
 
566
 
 
567
INSERT INTO t1 VALUES("down",   GeomFromText('POLYGON (( 0 -1, 0  1, 2  1, 2 -1, 0 -1))'));
 
568
INSERT INTO t1 VALUES("down2",  GeomFromText('POLYGON (( 0 -2, 0  0, 2  0, 2 -2, 0 -2))'));
 
569
INSERT INTO t1 VALUES("down3",  GeomFromText('POLYGON (( 0 -3, 0 -1, 2 -1, 2 -3, 0 -3))'));
 
570
 
 
571
INSERT INTO t1 VALUES("right",  GeomFromText('POLYGON (( 1 0, 1 2, 3 2, 3 0, 1 0))'));
 
572
INSERT INTO t1 VALUES("right2", GeomFromText('POLYGON (( 2 0, 2 2, 4 2, 4 0, 2 0))'));
 
573
INSERT INTO t1 VALUES("right3", GeomFromText('POLYGON (( 3 0, 3 2, 5 2, 5 0, 3 0))'));
 
574
 
 
575
INSERT INTO t1 VALUES("left",   GeomFromText('POLYGON (( -1 0, -1 2,  1 2,  1 0, -1 0))'));
 
576
INSERT INTO t1 VALUES("left2",  GeomFromText('POLYGON (( -2 0, -2 2,  0 2,  0 0, -2 0))'));
 
577
INSERT INTO t1 VALUES("left3",  GeomFromText('POLYGON (( -3 0, -3 2, -1 2, -1 0, -3 0))'));
 
578
 
 
579
SELECT GROUP_CONCAT(a2.name ORDER BY a2.name) AS mbrcontains  FROM t1 a1 JOIN t1 a2 ON MBRContains(   a1.square, a2.square) WHERE a1.name = "center" GROUP BY a1.name;
 
580
SELECT GROUP_CONCAT(a2.name ORDER BY a2.name) AS mbrdisjoint  FROM t1 a1 JOIN t1 a2 ON MBRDisjoint(   a1.square, a2.square) WHERE a1.name = "center" GROUP BY a1.name;
 
581
SELECT GROUP_CONCAT(a2.name ORDER BY a2.name) AS mbrequal     FROM t1 a1 JOIN t1 a2 ON MBREqual(      a1.square, a2.square) WHERE a1.name = "center" GROUP BY a1.name;
 
582
SELECT GROUP_CONCAT(a2.name ORDER BY a2.name) AS mbrintersect FROM t1 a1 JOIN t1 a2 ON MBRIntersects( a1.square, a2.square) WHERE a1.name = "center" GROUP BY a1.name;
 
583
SELECT GROUP_CONCAT(a2.name ORDER BY a2.name) AS mbroverlaps  FROM t1 a1 JOIN t1 a2 ON MBROverlaps(   a1.square, a2.square) WHERE a1.name = "center" GROUP BY a1.name;
 
584
SELECT GROUP_CONCAT(a2.name ORDER BY a2.name) AS mbrtouches   FROM t1 a1 JOIN t1 a2 ON MBRTouches(    a1.square, a2.square) WHERE a1.name = "center" GROUP BY a1.name;
 
585
SELECT GROUP_CONCAT(a2.name ORDER BY a2.name) AS mbrwithin    FROM t1 a1 JOIN t1 a2 ON MBRWithin(     a1.square, a2.square) WHERE a1.name = "center" GROUP BY a1.name;
 
586
 
 
587
SELECT GROUP_CONCAT(a2.name ORDER BY a2.name) AS contains     FROM t1 a1 JOIN t1 a2 ON Contains(      a1.square, a2.square) WHERE a1.name = "center" GROUP BY a1.name;
 
588
SELECT GROUP_CONCAT(a2.name ORDER BY a2.name) AS disjoint     FROM t1 a1 JOIN t1 a2 ON Disjoint(      a1.square, a2.square) WHERE a1.name = "center" GROUP BY a1.name;
 
589
SELECT GROUP_CONCAT(a2.name ORDER BY a2.name) AS equals       FROM t1 a1 JOIN t1 a2 ON Equals(        a1.square, a2.square) WHERE a1.name = "center" GROUP BY a1.name;
 
590
SELECT GROUP_CONCAT(a2.name ORDER BY a2.name) AS intersect    FROM t1 a1 JOIN t1 a2 ON Intersects(    a1.square, a2.square) WHERE a1.name = "center" GROUP BY a1.name;
 
591
SELECT GROUP_CONCAT(a2.name ORDER BY a2.name) AS overlaps     FROM t1 a1 JOIN t1 a2 ON Overlaps(      a1.square, a2.square) WHERE a1.name = "center" GROUP BY a1.name;
 
592
SELECT GROUP_CONCAT(a2.name ORDER BY a2.name) AS touches      FROM t1 a1 JOIN t1 a2 ON Touches(       a1.square, a2.square) WHERE a1.name = "center" GROUP BY a1.name;
 
593
SELECT GROUP_CONCAT(a2.name ORDER BY a2.name) AS within       FROM t1 a1 JOIN t1 a2 ON Within(        a1.square, a2.square) WHERE a1.name = "center" GROUP BY a1.name;
 
594
 
 
595
# Overlaps needs a few more tests, with point and line dimensions
 
596
 
 
597
SET @vert1   = GeomFromText('POLYGON ((0 -2, 0 2, 0 -2))');
 
598
SET @horiz1  = GeomFromText('POLYGON ((-2 0, 2 0, -2 0))');
 
599
SET @horiz2 = GeomFromText('POLYGON ((-1 0, 3 0, -1 0))');
 
600
SET @horiz3 = GeomFromText('POLYGON ((2 0, 3 0, 2 0))');
 
601
SET @point1 = GeomFromText('POLYGON ((0 0))');
 
602
SET @point2 = GeomFromText('POLYGON ((-2 0))');
 
603
 
 
604
SELECT GROUP_CONCAT(a1.name ORDER BY a1.name) AS overlaps FROM t1 a1 WHERE Overlaps(a1.square, @vert1) GROUP BY a1.name;
 
605
SELECT GROUP_CONCAT(a1.name ORDER BY a1.name) AS overlaps FROM t1 a1 WHERE Overlaps(a1.square, @horiz1) GROUP BY a1.name;
 
606
SELECT Overlaps(@horiz1, @vert1) FROM DUAL;
 
607
SELECT Overlaps(@horiz1, @horiz2) FROM DUAL;
 
608
SELECT Overlaps(@horiz1, @horiz3) FROM DUAL;
 
609
SELECT Overlaps(@horiz1, @point1) FROM DUAL;
 
610
SELECT Overlaps(@horiz1, @point2) FROM DUAL;
 
611
 
 
612
DROP TABLE t1;
 
613
 
 
614
#
 
615
# Bug#28763: Selecting geometry fields in UNION caused server crash.
 
616
#
 
617
create table t1(f1 geometry, f2 point, f3 linestring);
 
618
select f1 from t1 union select f1 from t1;
 
619
insert into t1 (f2,f3) values (GeomFromText('POINT(1 1)'),
 
620
  GeomFromText('LINESTRING(0 0,1 1,2 2)'));
 
621
select AsText(f2),AsText(f3) from t1;
 
622
select AsText(a) from (select f2 as a from t1 union select f3 from t1) t;
 
623
create table t2 as select f2 as a from t1 union select f3 from t1;
 
624
desc t2;
 
625
select AsText(a) from t2; 
 
626
drop table t1, t2;
 
627
 
 
628
#
 
629
# Bug #29166: MYsql crash when query is run
 
630
#
 
631
 
 
632
# The test query itself is not logged : too large output.
 
633
# The real test is the second query : see if the first hasn't crashed the
 
634
# server
 
635
--disable_query_log
 
636
--disable_result_log
 
637
SELECT AsText(GeometryFromText(CONCAT(
 
638
  'MULTIPOLYGON(((',
 
639
  REPEAT ('-0.00000000001234567890123456789012 -0.123456789012345678,', 1000),
 
640
  '-0.00000000001234567890123456789012 -0.123456789012345678',
 
641
  ')))'
 
642
))) AS a;
 
643
--enable_result_log
 
644
--enable_query_log
 
645
SELECT 1;
 
646
 
 
647
-- source include/gis_keys.inc
 
648
 
 
649
#
 
650
# Bug #31155 gis types in union'd select cause crash
 
651
#
 
652
 
 
653
create table `t1` (`col002` point)engine=myisam;
 
654
insert into t1 values (),(),();
 
655
select min(`col002`) from t1 union select `col002` from t1;
 
656
drop table t1;
 
657
 
 
658
--echo #
 
659
--echo # Bug #47780: crash when comparing GIS items from subquery
 
660
--echo #
 
661
 
 
662
CREATE TABLE t1(a INT, b MULTIPOLYGON);
 
663
INSERT INTO t1 VALUES 
 
664
  (0,
 
665
   GEOMFROMTEXT(
 
666
    'multipolygon(((1 2,3 4,5 6,7 8,9 8),(7 6,5 4,3 2,1 2,3 4)))'));
 
667
 
 
668
--echo # must not crash
 
669
SELECT 1 FROM t1 WHERE a <> (SELECT GEOMETRYCOLLECTIONFROMWKB(b) FROM t1);
 
670
 
 
671
DROP TABLE t1;
 
672
 
 
673
--echo #
 
674
--echo # Bug #49250 : spatial btree index corruption and crash
 
675
--echo # Part one : spatial syntax check
 
676
--echo #
 
677
 
 
678
--error ER_PARSE_ERROR
 
679
CREATE TABLE t1(col1 MULTIPOLYGON NOT NULL,
 
680
  SPATIAL INDEX USING BTREE (col1));
 
681
CREATE TABLE t2(col1 MULTIPOLYGON NOT NULL);
 
682
--error ER_PARSE_ERROR
 
683
CREATE SPATIAL INDEX USING BTREE ON t2(col);
 
684
--error ER_PARSE_ERROR
 
685
ALTER TABLE t2 ADD SPATIAL INDEX USING BTREE (col1);
 
686
 
 
687
DROP TABLE t2;
 
688
 
 
689
--echo End of 5.0 tests
 
690
 
 
691
 
 
692
#
 
693
# Bug #11335 View redefines column types
 
694
#
 
695
create table t1 (f1 tinyint(1), f2 char(1), f3 varchar(1), f4 geometry, f5 datetime);
 
696
create view v1 as select * from t1;
 
697
desc v1;
 
698
drop view v1;
 
699
drop table t1;
 
700
 
 
701
#
 
702
# Bug#44684: valgrind reports invalid reads in 
 
703
# Item_func_spatial_collection::val_str
 
704
#
 
705
SELECT MultiPoint(12345,'');
 
706
SELECT MultiPoint(123451,'');
 
707
SELECT MultiPoint(1234512,'');
 
708
SELECT MultiPoint(12345123,'');
 
709
 
 
710
SELECT MultiLineString(12345,'');
 
711
SELECT MultiLineString(123451,'');
 
712
SELECT MultiLineString(1234512,'');
 
713
SELECT MultiLineString(12345123,'');
 
714
 
 
715
SELECT LineString(12345,'');
 
716
SELECT LineString(123451,'');
 
717
SELECT LineString(1234512,'');
 
718
SELECT LineString(12345123,'');
 
719
 
 
720
SELECT Polygon(12345,'');
 
721
SELECT Polygon(123451,'');
 
722
SELECT Polygon(1234512,'');
 
723
SELECT Polygon(12345123,'');
 
724
 
 
725
--echo End of 5.1 tests