Download as pps, pdf, or txt
Download as pps, pdf, or txt
You are on page 1of 19

2

Welcome to

Oracle Spatial Workshop


for Management

Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1
2
Oracle Spatial
Concepts

Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


Objectives

After completing this lesson, you should be


able to do the following:
• Describe the supported geometric data types
• Define the Oracle8i Spatial data model
• Describe a spatial layer
• Describe the spatial query model
• Describe the concept of spatial indexing
• Identify spatial queries and spatial joins

Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-3
Types of Spatial Data
GIS (mapping) data CAD data

CAM data

Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-4
Geometric Primitive Types

• Points (X1, Y1)

• Line Strings (X1, Y1, Xn, Yn)


– self-crossing lines are supported
– lines that close to form a ring have no area
– straight or curved

Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-5
Geometric Primitive Types (cont.)

• Polygons (X1, Y1, Xn, Yn)


– Polygons are rotation independent (8.1.5). In
8.1.6, outer rings must be counter clockwise,
inner rings (voids) must be clockwise.
– coordinates must close and interior is implied
– interior area can be voided using additional
polygons (e.g. polygon with holes)
– self-crossing polygons are not supported
– straight or curved, optimized circle, rectangle
Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-6
Geometric PrimitiveTypes (cont.)

• Compound Line Strings (X1, Y1, Xn, Yn)


– combination of straight and curved lines
– self crossing lines are supported
– lines that close to form ring have no
area
• Compound Polygons (X1, Y1, Xn, Yn)
– combination of straight and curved lines
– same semantics as polygons
Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-7
Geometric Primitive Types
Arc line Compound Self-crossing
Point Line string string line string line strings

Valid

Polygon Compound Optimized Self-crossing


Polygon polygons
with hole polygon polygons

Not valid
Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-8
Spatial Data Model

Spatial layer

object model only:


Geometries • circular arcs
• circles
• optimized rectangle
• compound linestring
Elements • compound polygon

Point Linestring Polygon Compound Compound


Linestring Polygon

Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-9
Elements
• Basic building blocks of a geometry
• Same as geometric primitive types
• Element types Element 5
– Point
– Line Element 4
– Polygon Element 3
– Compound Linestring
Element 6 Element 2
– Compound Polygon
Element 1
• Constructed
using ordinates
Hawaii, USA

Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-10
Geometry
Geometry 1 Geometry 2
California Texas
• Represents a
spatial feature
• Consists of an
ordered set of
elements
Geometry 3 Geometry 4
Florida Hawaii

Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-11
Layers

• Consist of geometries
that share a common
set of attributes
• Layer is a geometry
column in a table

States layer

Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-12
Optimized Query Model

Exact
Secondary Result
Primary Set
Filter
Spatial Layer Filter Reduced
Data Data Set Spatial Exact
Spatial Index Result
Functions
Set

Table where Index retrieves Procedures


coordinates are area of interest that determine
stored (window) exact relationship
Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-13
Spatial Indexing
• Two basic types
– Quadtrees
– Based on a quad tree
decomposition
– Rtrees
– Based on minimum bounding
rectangles (MBRs)
• Provides an exclusive and exhaustive
coverage of spatial objects
• Indexes points, lines, and polygons
Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-14
Quad Tree Decomposition of Space

Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-15
Primary and Secondary Filter Concept

B B B

B I I B B

B I I I I B
B I I I I B

B I I I I B

B I I I B

B I B B B

B B B

Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-16
Spatial Window Queries

• Issued through SQL


• Contains a locational constraint, for
example:
– Find all policy holders in the projected
path of a hurricane
– Find all ATMs in my area

Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-17
Spatial Joins
(Spatial Cross Product)

• A join of two layers based on the spatial


component of the layers
• Implemented using spatial index and
spatial operators
• Very rare
• Example:
– Find all the wetlands within the
national parks
Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-18
Summary
In this lesson, you should have learned
about:
• The supported geometric primitive types
• The Oracle8i Spatial data model
• Spatial layers
• The spatial query model
• The concept of spatial indexing
• Spatial window queries and spatial joins

Copyright  Intergraph Hong Kong Limited, ®

Oracle Corporation, 2002. All rights reserved.


1-19

You might also like