MySQL Spatial Extensions - Boston MySQL Meetup April 2005

1,205 views

Published on

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
1,205
On SlideShare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
13
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

MySQL Spatial Extensions - Boston MySQL Meetup April 2005

  1. 1. MySQL Meetup MySQL Spatial Extensions Andrew Collins April 4th, 2005
  2. 2. Non- Geometry Instantiable Instantiable Geometry- Point Curve Surface Collection 1+ 2+ Multi- LineString Polygon MultiCurve MultiPoint Surface 1+ 1+ Multi- Multi- Line LinearRing 1+ Polygon LineString OpenGIS Simple Features Specification for SQL Geometry Class Hierarchy
  3. 3. Point MultiPoint LineString LinearRing Multi- Multi- Geometry- Polygon LineString Polygon Collection OpenGIS Simple Features Specification for SQL Spatial Data Model
  4. 4. SFS Methods : Basic ● GeometryType() – “POINT”, “POLYGON”, “LINEARRING” ... ● Envelope() – Polygon consisting of corner points of bounding box: ((MINX, MINY), (MAXX, MINY), (MAXX, MAXY), (MINX, MAXY), (MINX, MINY)) ● AsText() – Returns string representation of the geometry in Well-Known Text (WKT) format ● ... and a few other basic methods
  5. 5. SFS Methods : Spatial Relations ● Intersects(anotherGeometry : Geometry) – Returns true if this Geometry 'spatially intersects' anotherGeometry. ● Touches(anotherGeometry : Geometry) – Returns true if this Geometry 'spatially touches' anotherGeometry. ● Contains(anotherGeometry : Geometry) – Returns true if this Geometry 'spatially contains' anotherGeometry. ● ... and a few other spatial relational methods: – Equals(...), Disjoint(...), Crosses(...), Within(...), Overlaps(...), and Relate(...)
  6. 6. SFS Methods : Spatial Analysis ● Distance(anotherGeometry : Geometry) – Return shortest distance between this Geometry and anotherGeometry. ● Union(anotherGeometry : Geometry) – Returns the point set union of this Geometry and anotherGeometry. ● Difference(anotherGeometry : Geometry) – Returns the point set difference of this Geometry and anotherGeometry. ● ... and a few other spatial relational methods: – SymDifference(anotherGeometry : Geometry), Buffer(distance : Double), ConvexHull( ), ...
  7. 7. “Not Yet Implemented” ● The OpenGIS SFS specification is great, but... – ... the spatial extensions are only available as of MySQL 4.1.x – ... and the SFS specification is not fully implemented. ● Many of the spatial relations and analysis methods are “not yet implemented.” – This is understandable given the fact that “robust” implementations of these methods are not easy to create.
  8. 8. JTS Topology Suite ● The JTS Topology Suite
  9. 9. GML : Geography Markup Language ● Another OpenGIS specification used to format Simple Features in XML – XSLT available to translate GML to WKT – ... and MySQL INSERT commands
  10. 10. Links ● Open Geospatial Consortium, Inc. (OGC) http://www.opengeospatial.org/ ● OGC: Simple Features - SQL (SFS) http://www.opengeospatial.org/docs/99-049.pdf ● Spatial Extensions in MySQL http://dev.mysql.com/doc/mysql/en/spatial-extensions-in-mysql.html ● Geography Markup Language (GML3.0) http://www.opengeospatial.org/specs/?page=specs ● JTS Topology Suite http://www.vividsolutions.com/jts/JTSHome.htm

×