Category Spatial

Visualizing Spatial Data in Oracle SQL Developer

As the official SQL client, Oracle SQL Developer is popular. It offers a function to view spatial data using Map View tool.

Assume you have an Oracle Spatial-enabled database, you have a Shape column with SDO_GEOMETRY data type in your spatial table. This column contains spatial data. How to see the actual map or shapes in Oracle SQL Developer?

Map View Toolbar

First, we may do a query for this spatial table, e.g. SELECT * FROM LGS_Land_Parcel_Geo.

Second, go to SQL Developer menu View \ Map View to turn on Map View panel. Click + button in the toolbar of Map View panel to open Map Query box. Insert above query statement and provide a Map Title for your query. Click OK to close the dialog box.

Map View

The map of this table shows in left Map View panel...

Read More

Spatial Data Migration: From Oracle to SQL Server

I spent many years on spatial data modeling and migration on ESRI ArcGIS and ArcSDE, served nature resources sector. Spatial data migration is common when we get involved in map-related applications.

I worked on a project which requested spatial data migration from Oracle to SQL Server. I would like to give you a quick walk-through on how it can be done correctly.

First, let’s introduce some basic concepts:

  • WKT & WKB: Well-known Text & Well-known Binary, text markup language defined by Open Geospatial Consortium (OGC), supported by Oracle 9i+, MS SQL Server 2008 R2+, PostgreSQL PostGIS M2, etc.
  • Geometry & Geography: Geometry: Euclidean (flat) coordinate system; Geography: Round-earth coordinate system.
  • Spatial Data Types: consist of simple types and collection types as illustrated below.

Second...

Read More