Spatial database


A spatial database is a database that is optimized for storing and querying data that represents objects defined in a geometric space. Most spatial databases allow the representation of simple geometric objects such as points, lines and polygons. Some spatial databases handle more complex structures such as 3D objects, topological coverages, linear networks, and TINs. While typical databases have developed to manage various numeric and character types of data, such databases require additional functionality to process spatial data types efficiently, and developers have often added geometry or feature data types. The Open Geospatial Consortium developed the Simple Features specification and sets standards for adding spatial functionality to database systems. The SQL/MM Spatial ISO/IEC standard is a part the SQL/MM multimedia standard and extends the Simple Features standard with data types that support circular interpolations.

Geodatabase

A geodatabase is a database of geographic data, such as countries, administrative divisions, cities, and related information. Such databases can be useful for websites that wish to identify the locations of their visitors for customization purposes.

Characteristics

Database systems use indexes to quickly look up values; however, this way of indexing data is not optimal for spatial queries. Instead, spatial databases use a spatial index to speed up database operations.
In addition to typical SQL queries such as SELECT statements, spatial databases can perform a wide variety of spatial operations. The following operations and many more are specified by the Open Geospatial Consortium standard:
Some databases support only simplified or modified sets of these operations, especially in cases of NoSQL systems like MongoDB and CouchDB.

Spatial index

Spatial indices are used by spatial databases to optimize spatial queries. Conventional index types do not efficiently handle spatial queries such as how far two points differ, or whether points fall within a spatial area of interest. Common spatial index methods include:

List

DBSLicenseDistributedSpatial objectsSpatial functionsPostgreSQL interfaceUMN MapServer interfaceDocumentationModifiableHDFS
GeoMesaApache License 2.0yesyes yes no noparts of the functions, a few exampleswith Simple Feature Access in Java Virtual Machine and Apache Spark are all kinds of tasks solvableyes
H2 LGPL 3, GPL 3 beforenoyes Simple Feature Access and custom functions for H2Networkyesnoyes SQLno
IngresGPL or proprietaryyes yes Geometry Engine, Open Sourcenowith MapScriptjust brieflywith C and OMEno
Neo4J-spatialGNU affero general public licensenoyes yes nonojust brieflyfork of JTSno
PostgreSQL with PostGISGNU General Public Licensenoyes yes yesyesdetailedSQL, in connection with Rno
Postgres-XL with PostGISMozilla public license and GNU general public licenseyesyes yes yesyesPostGIS: yes, Postgres-XL: brieflySQL, in connection with R or Tcl or Pythonno
Rasdamanserver GPL, client LGPL, enterprise proprietaryyesjust rasterraster manipulation with rasqlyeswith Web Coverage Service or Web Processing Servicedetailed wikiown defined function in enterprise editionno
RethinkDBAGPLyesyes
  • distance
  • getIntersecting
  • getNearest
  • includes
  • intersects
nonoofficial documentationforkingno