Make your own free website on Tripod.com
anihead.gif (25759 bytes)

Object-relation model

Standard specification

(NCITS. Doc. No.: X3H7-93-007v12b)

Standard object-relation model (SQL3)
see also "Definition of object"

One of the basic ideas behind the object extensions in SQL3 is that, in addition to the normal built-in types defined by SQL, user-defined types may also be defined. These types may be used in the same way as built-in types. For example, columns in relational tables may be defined as taking values of user-defined types, as well as built-in types. A user-defined abstract data type (ADT) definition encapsulates attributes and operations in a single entity. In SQL3, an abstract data type (ADT) is defined by specifying a set of declarations of the stored attributes that represent the value of the ADT, the operations that define the equality and ordering relationships of the ADT, and the operations that define the behavior (and any virtual attributes) of the ADT. Operations are implemented by procedures called routines. ADTs can also be defined as subtypes of other ADTs. A subtype inherits the structure and behavior of its supertypes (multiple inheritance is supported). Instances of ADTs can be persistently stored in the database only by storing them in columns of tables.

A row type is a sequence of field name/data type pairs resembling a table definition. Two rows are type-equivalent if both have the same number of fields and every pair of fields in the same position have compatible types. The row type provides a data type that can represent the types of rows in tables, so that complete rows can be stored in variables, passed as arguments to routines, and returned as return values from function invocations. This facility also allows columns in tables to contain row values. A named row type is a row type with a name assigned to it. A named row type is effectively a user-defined data type with a non-encapsulated internal structure (consisting of its fields). A named row type can be used to specify the types of rows in table definitions. A named row type can also be used to define a reference type. A value of the reference type defined for a specific row type is a unique value which identifies a specific instance of the row type within some (top level) database table. A reference type value can be stored in one table and used as a direct reference ("pointer") to a specific row in another table, just as an object identifier in other object models allows one object to directly reference another object. The same reference type value can be stored in multiple rows, thus allowing the referenced row to be "shared" by those rows.

Tables have also been enhanced with a subtable facility. A table can be declared as a subtable of one or more supertables (it is then a direct subtable of these supertables), using an UNDER clause associated with the table definition. When a subtable is defined, the subtable inherits every column from its supertables, and may also define columns of its own. The subtable facility is completely independent from the ADT subtype facility.

 

Apendix. Definition of object

The analysis and design models included, and their identifications, are:

D: Booch Design
CA: Coad et al. Analysis
CD: Coad et al. Design
EA: Embly et al. Analysis
FA: Coleman et al Analysis
FD: Coleman et al Design
FC: Coleman et al Construction
HA: Henderson-Sellers et al. Analysis and Design
JA: Jacobson et al. Analysis
JD: Jacobson et al. Design
MD: Meyer Design
MC: Meyer Construction
NA: Walden et al. Analysis and Design
OA: Odell et al. Analysis
RA: Rumbaugh et al. Analysis
RD: Rumbaugh et al. Design
SA: Shlaer et al. Analysis
SD: Shlaer et al. Design
WD: Wirfs-Brock et al. Design

SA: "Definition: An object is an abstraction of a set of real-world things: such that:

'Object' is used in two senses: 1. a typical unspecified instance 2. the class of all instances.

CA: "An abstraction of something in the domain of a problem or its implementation, reflecting the capabilities of a system to keep information about it, interact with it, or both; an encapsulation of Attribute values and their exclusive Services. (Synonym: an Instance.)"

RA: "A discrete, distinguishable entity which quantizes data." "A concept, abstraction, or thing with crisp boundaries and meaning for the problem at large." Instance.

JA: "An object is characterized by a number of operations and a state which remembers the effect of these operations." Instance

WD: "The primitive element of object-oriented programming is an object. ... an object retains certain information, and knows how to perform certain operations." Instance.

MD: An object is a data structure of a specified abstract data type. "...a class is a type, an object is an instance of a type. ...an object is a purely dynamic concept, which belongs not to the program text, but to the memory of the computer, where objects occupy some space at run-time once they [have] been created..."

EA: "An object is a person, place, or thing. An object may be physical or conceptual."

FA: "An object corresponds to a concept, abstraction, or thing that can be distinctly identified. During analysis, objects have attributes and may be involved in relationships with other objects. [The authors do not maintain a distinction between 'thing of interest' and 'abstraction representing thing.'] "The reader should note that the notion of object during analysis is different from that usually employed. Many methods permit analysis objects to exhibit dynamic behavior and have a method interface; this is not the case in [this method], where analysis object have no interface and no dynamic behavior."

FD: "During design, the notion of object is extended by the introduction of methods and object attributes."

FC: "In the implementation phase the notion of object is determined by the programming language."

OA: "An object is anything to which a concept applies. It is an instance of a concept." 'Object' is used both for the model of a thing and for the thing itself.

BD: "An object has state, behavior, and identity; the structure and behavior of similar objects are defined in their common class; the terms instance and object are interchangeable."

'Object' is used both for the model of a thing and for the thing itself.

"...[S]ome things ... are distinctly not objects. For example, [some] attributes ... On the other hand, these things are all potentially properties of other objects."

HA: "An object is a particular instance of a class".

NA: An object is an instance of a class "built according to the description in [the] class."