# Object-based spatial database

An object-based spatial database is a spatial database that stores the location as objects. The object-based spatial model treats the world as surface littered with recognizable objects (e.g. cities, rivers), which exist independent of their locations.
Objects can be simple as polygons and lines, or be more complex to represent cities.
While a field-based data model sees the world as a continuous surface over which features (e.g. elevation) vary, using an object-based spatial database, it is easier to store additional attributes with the objects, such as direction, speed, etc. Using these attributes can make it easier to answer queries like "find all tanks whose speed is 10 km and oriented to north". Or "find all enemy tanks in a certain region".
Storing attributes with objects can provide better result presentation and improved manipulation capabilities in a more efficient way. In a field-based data model, this information is usually stored at different layers and it is harder to extract different information from various layers. This data model can be applied above the ER as in GERM model and GISER.
S.Shekhar introduces direction as a spatial object and presents a solution to object-direction-based queries.

## Data model representation

The most common representations for the data model follow.

### PostGIS

An open-source software program that adds support for geographic objects to the PostgreSQL object–relational database. PostGIS follows the Simple Features for SQL specification from the Open Geospatial Consortium.

### OMT-G

Provides a UML representation for geographic applications, it can represent the concept of field, object and provides a way to differentiate between spatial relation and simple association.

### GraphDB

Represents a framework of objects as classes that are partitioned into three kinds of classes: simple classes, link classes, and path classes. Objects of a simple class are on the one hand just like objects in other models. They have an object type and an object identity and can have attributes whose values are either of a data type (e.g. integer, string) or of an object type (that is, an attribute may contain a reference to another object). So the structure of an object is basically that of a tuple or record. On the other hand, objects of a simple class are nodes of the database graph – the whole database can also be viewed as a single graph. Objects of a link class are like objects of a simple class but additionally contain two distinguished references to source and target objects (belonging to simple classes), which makes them edges of the database graph. Finally, an object of a path class is like an object of a simple class, but contains additionally a list of references to node and edge objects which form a path over the database graph.

### GEIS

Represent a data model to store geographic information on top of EER model, GEIS define the input data model and provide the following for data model Geometry. In the GISER model, geometry is an entity that is related to a spatial object by the relationship determines shape of. Additional entities represent the primitives such as points, lines, and polygons as proposed in related models. Topology. Topology is a property belonging to a spatial object and that property remains unaltered even when the object deforms. An example is a road network. The two nodes in the network thus remain connected even if the path between the nodes is changed by road construction. In order to represent the topology, the basic primitives such as networks (i.e., graphs) and partitions are provided. Additional primitives can be added on lines of the Worboy model, This system support representation for stored data.

### Oracle spatial

Oracle spatial is a component of enterprise Oracle 10g and provides support to stores object such as road on top of the current implentend construction but it used network data model to store geographic data as nodes and links (a graph representation) with each node or links it has a set of attributes. For example, a route object can be added to the database.

### GRASS GIS

It supports raster and some set of vector representation.