X

Oracle Spatial and Graph – technical tips, best practices, and news from the product team

  • March 27, 2020

Options for Visualizing Spatial Data in Oracle

Carol Palmer
Senior Principal Product Manager

Part One (Part Two coming in April)

Overview

You may be aware of the spatial data types and analysis in Oracle Database…but did you know about the many development tools for creating maps to visualize your data? Do you have customer, sales territory, asset information in your database that you and your end users want to visualize and interact with on a map? Whether you’re a seasoned database user or developer, or are just starting to look at using Oracle’s spatial features, you have several choices of tools to create the perfect map to fit your needs.

This blog discusses Oracle options for visualizing your spatial data in Oracle Database.  Visualization means you see your geospatial data displayed on a map. There are different options you can use to visualize your data, such as Oracle products, tools and APIs. In addition, you can use open source tools and APIs. Although all of these options are different, the basic architecture and data flow is the same for each one.

Oracle Visualization Options

Oracle provides products, tools, and APIs for visualizing spatial data stored in Oracle Database. These include Map Builder, Spatial Map Visualization Component (SMVC), Oracle Analytics Cloud, Spatial Studio, and map visualization APIs.  (Note that the Spatial Map Visualization Component was formerly known as MapViewer.)

Map Tools and Products

Map Builder

Map Builder is a standalone Java-based desktop application. The latest version is 20c and supports Oracle Autonomous Database wallet connections. It has a simple UI for you to pan, zoom, or identify features on a map. It utilizes public Oracle spatial Java libraries such as SDOAPI which can transform database geometries or GeoRaster objects into corresponding objects in Java.

It is a useful tool for quickly visualizing any kind of geospatial data stored in your Oracle spatial database tables. You can run simple and adhoc SQL queries (via JDBC) and visualize the spatial data result sets inside Map Builder.

It is typically used as a companion tool to the Spatial Map Visualization Component, which will be discussed next.

 

Spatial Map Visualization Component

SMVC is a Java middleware component that is deployed and run inside your JavaEE containers, including WebLogic Server and Tomcat. It is used by many customers and is integrated into a number of Oracle products, such as Oracle Analytics Cloud.

You can think of SMVC as a single, large server that is running in your WebLogic Server instance. It provides enterprise level mapping and data services. It can be used as a raster or image tile server and can generate or stream a high volume of vector data on the fly. SMVC can also generate GeoJSON data out of your tables or queries on the fly. You can use SMVVC to publish your geospatial data using the OGC standard Web Map Service (WMS) and OGC Web Map Tile Service (WMTS). Depending on your application needs, you may be using one or more of these services.

 Raster/Image Tile Server

The Raster/Image Tile Server generates and caches map tile images. Tiles are displayed using the Oracle Maps JavaScript API (more below). Tiles can also be displayed using any open source mapping API (Leaflet, OpenLayer, etc.) when the tiling scheme conforms to the standard World Mercator tile scheme.

GeoJSON Data Server

GeoJSON Data Server generates GeoJSON on the fly. GeoJSON is the spatial flavor of JSON, a standard, lightweight data interchange format popular for web applications.  It supports simplifying geometries while generating GeoJSON. GeoJSON data can be displayed using Oracle Maps JS API or any open source mapping API (Leaflet, OpenLayer, etc.).

Vector Tile Server

Vector Tile Server generates vector tiles on the fly. Each tile includes a single SMVC-defined layer/theme only. Vector tiles are a format for encoding map and business data in a single file.  This is a very compact binary format that enables large volumes of geometry data to be transmitted to the client.  Web map applications using vector tiles are versatile (since attributes are included along with the geometries, which users can view with tooltips) and highly performant. Vector tiles can be displayed using open source mapping APIs (OpenLayer, Mapbox GL JS API, etc.).

Map Visualization APIs

Java APIs

In addition to the Spatial ready-to-use tools, Oracle provides map visualization APIs. If you are a Java developer and you want to develop your Java-based applications or services, then you probably want to start with these Java Packages. They allow you to transform your native spatial data types stored in the database - geometries, GeoRaster, network model, and topology – and bring them over to Java where you can manipulate and process that data.

These Java packages aren’t specifically for visualization. They are used to process your business and geospatial objects or just display them. Visualization is typically done using standard Java2D graphics API.

Oracle Spatial Java API

 

Oracle Maps JavaScript API

Oracle Maps JavaScript API is also known as the V2 API, or HTML5 API. It is designed to work with the Spatial Map Visualization Component as the backend. It can display both image tiles and GeoJSON data and provides a lot of interactivity. The V2 API can also be used in standalone web applications – you don’t have to use SMVC. For example, you can load your spatial data from a GeoJSON service and use the V2 API to create your web map application.

The V2 API has some advanced geometry editing functions including splitting and merging polygons.

Map Visualization downloads:  https://www.oracle.com/database/technologies/spatial-studio/spatial-graph-map-vis-downloads.html

Map Visualization with Oracle Spatial and Graph – presentation from Analytics and Data Summit 2020

Oracle Spatial & Graph Map Visualization's Developer Guide

 

Visualizing Spatial Data (Part Two) will include easy to use, low code options such as Oracle Analytics Cloud, Spatial Studio, and open source tools and APIs. Stay tuned.

Be the first to comment

Comments ( 0 )
Please enter your name.Please provide a valid email address.Please enter a comment.CAPTCHA challenge response provided was incorrect. Please try again.