DBMS-Data Models

Data Models

 

A data model is a picture or description which shows how the data is to be arranged to achieve a given task.

It is a clear model which specifies how the data items are arranged in a given model.

Some data models which gives a clear picture which shows the manner in which the data records are connected or related within a file structure. These are called structural data models.

DBMS organize and structure data so that it can be retrieved and manipulated by different users and application programs

The data structures and access techniques provided by a particular DBMS are called its data model.

 

 

Types Of Data Models:

 

1)Hierarchical databases model

2)Network databases model

3)Relational databases model

4) Object oriented databases model

 

Hierarchical databases model:

 

Hierarchical Databases is most commonly used with mainframe systems.

It is one of the oldest methods of organizing and storing data and it is still used by some organizations for making travel reservations.

A hierarchical database is organized in pyramid fashion, like the branches of a tree extending downwards.

In this model, related fields or records are grouped together so that there are higher-level records and lower-level records, just like the parents in a family tree sit above the subordinated children.

Based on this analogy, the parent record at the top of the pyramid is called the root record.

Network databases model:

 

 

Network databases are similar to hierarchical databases by also having a hierarchical structure. There are a few key differences, however.

Instead of looking like an upside-down tree, a network database looks more like a cobweb or interconnected network of records. In network databases, children are called members and parents are called owners. The most important difference is that each child or member can have more than one parent (or owner).

Similar to hierarchical databases, network databases are principally used on mainframe computers.

Since more connections can be made between different types of data, network databases are considered more flexible. However, two limitations must be considered when using this kind of database.

Similar to hierarchical databases, network databases must be defined in advance. There is also a limit to the number of connections that can be made between records.

 

Relational databases Model :

 

Pre-relational models depended upon being able to determine explicitly where and how individual records were stored.

Early relational proponents argued that the relational data model viewed information logically rather than physically, but this is not quite correct.

Earlier data models associated the logical and physical aspects of information together; logically-related information was stored in physical proximity within a data file. The relational data model first separated the logical from the physical aspects.

The relational data model looks at information as an unordered collection of "relations."

Each relation is populated with unordered "tuples" of the same unordered "field" structure.

Fields may only contain values of a well-defined ("atomic") domain or the null value. The unordered aspect needs to be emphasized. For expository purposes, relations are often viewed as "tables".

The tuples constitute the "rows" of the table; values for a specific field constitute "columns". However, the "table data model" tends to impose a very non-relational ordering on both tuples and fields. Relations are an abstraction of how data is stored; tables are just one of many possible implementations.

 There is a strong tendency to refer to an individual tuple/row as a "record" because collections of fields in other models are called records. "Attribute" is often used synonymously with field.

 

To be sure, "unordered" implies neither "chaotic" nor "random". Relations and Fields are named uniquely and identified easily. Distinguishing between tuples is more subtle since the order is not pre-defined.

Rather than depending upon relative (as in hierarchy) or absolute (as in network) locations, tuples may only be differentiated according to their contents.

Consequently, duplicate tuples are not permitted within a single relation. Even more strongly, distinct tuples must have a unique "key" (some combination of a relation's named fields).

The set of minimal keys includes one "primary key"; the rest are "candidate keys". Within a tuple, references to other tuples are expressed as a "foreign key," which should contain the values of the referenced tuple's primary key.

Relational theory provides a firm mathematical foundation for data management. Set theory could be applied to relations using relational algebraic operations (union, intersection, join, projection, etc.).

 

Object oriented databases

 

 

A data model is a logic organization of the real world objects (entities), constraints on them, and the relationships among objects. A DB language is a concrete syntax for a data model. A DB system implements a data model

A core object-oriented data model consists of the following basic object-oriented concepts:

1)Object and object identifier:

Any real world entity is uniformly modeled as an object (associated with a unique id: used to pinpoint an object to retrieve)

2) attributes and methods:

Here every object has a state (the set of values for the attributes of the object) and a behavior (the set of methods - program code - which operate on the state of the object). The state and behavior encapsulated in an object are accessed or invoked from outside the object only through explicit message passing.

 An attribute is an instance variable, whose domain may be any class: user-defined or primitive. A class composition hierarchy (aggregation relationship) is orthogonal to the concept of a class hierarchy. The link in a class composition hierarchy may form cycles.

3) class:

a means of grouping all the objects which share the same set of attributes and methods. An object must belong to only one class as an instance of that class (instance-of relationship). A class is similar to an abstract data type. A class may also be primitive (no attributes), e.g., integer, string, Boolean

 

4) Class hierarchy and inheritance:

derive a new class (subclass) from an existing class (superclass). The subclass inherits all the attributes and methods of the existing class and may have additional attributes and methods. single inheritance (class hierarchy) vs. multiple inheritance (class lattice).

 

Note:These details are as per our knowledge if there is any mistake please let us know

Thanks


Reference:archive.mu.ac.in,wikipedia


Comments

Post a Comment

Popular posts from this blog

JavaScript: Async functions (async/await)

DATA Structures :Binary Search Trees

Angular 2+ :@view Child

Angular -Lazy Loading

OOPS Concepts-JAVA