How is ST_Geometry implemented?

ST_Geometry is implemented as a user-defined type that can be used in databases and geodatabases. In IBM DB2, IBM Informix, Oracle, and PostgreSQL. ST_Geometry also can be used in SQLite databases.

In DB2 and Informix, an additional spatial module is required to use ST_Geometry in the database and geodatabase.

ST_Geometry is present by default in geodatabases created in Oracle and PostgreSQL. If you do not use geodatabase functionality, you can add the ST_Geometry type to Oracle and PostgreSQL databases using the Create Spatial Type geoprocessing tool.

You can use the CreateSQLiteDatabase ArcPy function to create an SQLite database that contains the ST_Geometry type. Alternatively, you can use the CreateOGCTables SQL function to create the ST_Geometry data type in an existing SQLite database.

Each DBMS supports ST_Geometry as follows:

DBMS

Description

Oracle

The ST_Geometry data type is the default geometry storage type for enterprise geodatabases in Oracle. It also can be installed in an Oracle database using the Create Spatial Type geoprocessing tool. It is a high-performance storage type that includes ISO- and OGC-compliant SQL access to spatial data.

IBM DB2

The DB2 Spatial Extender provided by IBM as part of the DB2 product is the only option used to store feature geometry in geodatabases in DB2. It was codeveloped by Esri and IBM and is a high-performance storage type that provides ISO- and OGC-compliant SQL access to spatial data.

Be aware that there are some differences in SQL syntax between DB2 for z/OS and DB2 for Windows/Linux/UNIX. Consult the DB2 documentation for proper syntax for the DBMS version you are using.

IBM Informix

The Informix Spatial DataBlade provided by IBM as part of the Informix product is the only option used to store feature geometry in geodatabases in Informix. It was codeveloped by Esri and IBM and is a high-performance storage type that provides ISO- and OGC-compliant SQL access to spatial data.

PostgreSQL

The ST_Geometry data type is the default type for storing feature geometry in enterprise geodatabases in PostgreSQL. It also can be installed in a PostgreSQL database using the Create Spatial Type geoprocessing tool. As with the other DBMS implementations, the PostgreSQL implementation provides ISO- and OGC-compliant SQL access to spatial data.

SQLite

The ST_Geometry data type in SQLite is implemented using an st_geometry library and a geometryblob column. The ST_Geometry SQL functions are stored in the st_geometry library rather than the database. The functions provide ISO- and OGC-compliant SQL access to spatial data in SQLite.

ST_Geometry by DBMS

Related Topics

6/19/2015