Top 5 Recent Articles
ARTICLES CATEGORIES
- Algorithms (22)
- All (399)
- Biography (1)
- Blog (44)
- Business Requirements (1)
- Commentary (1)
- Conversion (2)
- Customers (2)
- Data Models (1)
- Education (2)
- GeoRaptor (13)
- GPS (1)
- Image Processing (2)
- Import Export (8)
- Licensing (2)
- LiDAR (1)
- Linear Referencing (4)
- Manifold GIS (3)
- Mapping (1)
- MySQL Spatial (7)
- Networking and Routing (including Optimization) (5)
- Open Source (18)
- Oracle Spatial and Locator (194)
- Partitioning (1)
- PostGIS (36)
- Projections (1)
- Published Articles (1)
- qGIS (1)
- Recommendations (1)
- Services (1)
- Software Change Log (1)
- Source Code (37)
- Space Curves (9)
- Spatial Database Functions (109)
- Spatial DB comparison (1)
- Spatial XML Processing (11)
- SQL Server Spatial (92)
- Standards (3)
- Stored Procedure (17)
- Tessellation or Gridding (10)
- Tools (2)
- Topological Relationships (1)
- Training (2)
- Triangulation (2)
Spatial Database Comparison
I thought I would try and create a table comparing all the native spatial types of the main database products around today.
Because this is a “work in progress”, I will be contantly updating it. Where I have something wrong or have missed a product, please email me and I will correct the table.
Regina makes a point about PostGIS vs ESRI’s Spatial Type. When I have downloaded and installed PostgreSQL I have done so via the public PostgreSQL download site. PostGIS is shipped with the Windows installer so as far as I am concerned PostGIS (which I have never downloaded from Refractions) is thus the “official” native type for PostgreSQL until such times PostgreSQL itself moves to revoke that status by removing it from the standard installers.
Dale Lutz pointed me at the SpatialLite implementation for SQLLite. Here the SpatialLite implementation is maintained completely separately from SQLLite so, at the moment, I don’t think I can include it in the table.
With regards ESRI. ESRI is not a manufacturer of a generic database which could be used to completely supplant Oracle, SQL Server etc. It makes extension products (ESRI spatial type) for some commercial databases but this product is in direct competition with the owner and manufacturer of these products. Therefore I do not consider it to be a native extension. (I also cannot test or use it without having to pay ESRI for the privilege – not so with the main vendors with their Express editions or the free open source alternatives.) Since MapInfo also creates and sells SpatialWare I may consider creating a separate table for these products once I am satisfied that the table below is accurate, easy to read and complete.
While 1 I have included a column on the storage format of the spatial type I want to make something perfectly clear: it is irrelevant. I was taught in computer science about Codd’s relational theory and have always believed in the quality of the mathematics and science that went into that theory. That most of the modern relational databases do not fully implement Codd’s theory is an accepted fact. But even so we should aspire to trying to implement relational theory as best we can. In this light I want to quote something that Chris Date and Hugh Darwen wrote in their book Foundation for Future Database Systems: The Third Manifesto (2nd Edition).
“What we are saying is that, in the relational world, a domain is a data type, system- or user-defined, whose values are manipulable soley by means of the operators defined for the type in question (and whose internal representation can be arbitrarily complex but is hidden from the user).” [Emphasis added by myself]
Here is my attempt at classification/documentation.
Database |
Extension or Component |
Storage Format 1 |
) Storage Format Compliance |
Dimensions |
Spatial Reference System |
Geometric Organisation |
Access Standard |
Indexing |
Oracle | Locator / Spatial |
Oracle Object consisting of numbers and arrays |
SQL/MM components (arrays, numbers and objects) |
3D + Measure |
EPSG |
OGC SFS SQL/MM (circular arcs) |
Proprietary but open eg sdo_util.GetVertices; SDO_INSIDE() Also SQL/MM |
QuadTree (no longer recommended) and RTree (preferred) |
SQL Server 2008 |
Spatial |
Proprietary (Actually .NET Common Language Runtime – CLR – Data Types) |
None |
2.5D + Measure |
EPSG |
OGC SFS 1.1 |
OGC 1.1 + Extensions eg MakeValid() BufferWithTolerance() Reduce() (Douglas-Peuker) Not Spatial Schema tables (eg GEOMETRY_COLUMNS and SPATIAL_REF_SYS |
Grid |
PostgreSQL | PostGIS |
Extended WKB |
OGC SFS 1.1 |
EPSG |
OGC SFS SQL/MM (partially) |
SFS 1.1.0 SQL/MM + proprietary extensions eg ST_AddPoint(linestring, point, [<position>]); ST_Affine(geometry, float8, float8, float8, float8, float8, float8) |
R-Tree index implemented on top of. GiST |
|
MySQL | none | Proprietary | None | ISO/EPSG |
OGC SFS |
OGC 1.1 |
RTree | |
IBM DB2 |
Spatial Extender |
Smart Large Object (BLOB) |
Unknown | 2.5D | ISO/EPSG |
OGC SFS 1.1 |
OGC 1.1 + extensions eg SE_VertexUpdate() SE_VertexAppend() SE_VertexDelete() |
RTree |
Informix | GeoDetic Blade | RTree | ||||||
DB2 | Spatial Blade | RTree |
Documentation
- MySQL Spatial General Functions
- Oracle LRS Objects
- Oracle Spatial Exporter (Java + pl/SQL)
- Oracle Spatial Object Functions
- Oracle Spatial Object Functions (Multi Page)
- PostGIS pl/pgSQL Functions
- SC4O Oracle Java Topology Suite (Java + pl/SQL)
- SQL Server Spatial General TSQL Functions
- SQL Server Spatial LRS TSQL Functions