Home / Software / The different Database Models Explained

The different Database Models Explained

Many different types of databases exist, some simple, others extremely complex. Companies and individuals access these databases every day. If you look up a number in the telephone book, you are simply looking at a printed report from a database. If you make an online purchase, you are accessing a database. Databases have become ubiquitous in our lives.

However, many companies are still dealing with paperwork on a day-to-day basis. One of the basic reasons why many companies, especially smaller companies are reticent in moving their paper-based systems to computers is a lack of understanding of computing basics.

When many people hear about databases, their eyes glaze over as they picture a large white room filled with expensive equipment. In decades past, this may have been true, however, the modern database comes in many forms, and in most cases, can be hosted on nearly any system, including the computer currently sitting on your desk.

There are six commonly recognized models (types) of database that are useful for different types of data or information. Depending upon your specific needs, one of these models should be appropriate for your migration from paper based systems to a database.

The six recognized models are:

– Relational database
– Flat-file database
– Hierarchical database
– Network database
– Object-oriented database
– Object-relational database

Flat-file database:

The most basic database model is the flat-file database. In this model, data is stored in a formatted text file formatted as either a “fixed length” or “character delimited” text file.

Following is an example of a “fixed length” file:

1 John Doe 10/10/1990
2 Jane Smith 12/12/2001

In this example, the file is formatted in columns of a fixed length. In this case, column 1 has a record identity field that uses characters 1 – 4; column 2 is a name field that uses characters 5 16; column 3 is a date field using characters 17 to the end of the line. Each column has a set width, which is why this is called a “fixed length” file.

Following is an example of a “character delimited” file which uses the semicolon (;’) as the field delimiter:

1;John Doe;10/10/1990
2;Jane Smith;12/12/2001

This is the same information as provided in the first example, however, in this case, the first column is determined as all information before the first semicolon, the second column is all information between the first and second semicolon, and the third column is all information after the last semicolon.

The biggest advantage of a flat-file database is that the format is almost universally recognized by all computing systems. Flat-file databases are commonly used as temporary files and/or holding files for data in the process of being migrated between disparate systems.

Due to the numerous limitations of a flat-file database, it is rare to see one used except in the most basic of applications.

Hierarchical database:

A hierarchical database is a step above a flat file database. Records and data are still stored in a flat-file format, however, in this model, relationships are established between multiple flat-file repositories to make data easier to manage. Data is stored in a file structure based on the concept of parent/child relationships. In this model, a parent table is at the top of the structure, which contains pointers to child tables (additional text files) that contain related data.

Each parent table can have multiple child tables, however, each child table can have only one parent table. To access the child table, you must go through the parent table.

Data access and management is considerably easier in a hierarchical database than in a flat-file database, however, users must be very familiar with the database hierarchy. Additionally, though better than a flat-file database, the hierarchical database still lags far behind the relational database in maintaining data integrity.

Network database:

Just as the hierarchical database is a step above the flat-file database, the network database is a step above the hierarchical database. The network database makes one major improvement. In this model, relationships can be established between the parent and child tables in both directions. This means that a child table can have multiple parents, the same as a parent table can have multiple child tables linked.

The network database model makes it much easier to build more complex databases, however, the user still must have a good understanding of the underlying structure to efficiently access and manage the data.

Relational database:

The relational database model is the most commonly used today. Data management is easier through the use of referential integrity. As well, retrieving data is quick and relatively easy through the usage of the international standard Structured Query Language (SQL). Changes made in one portion of the database are propagated throughout the database through the usage of integrity constraints and relational links.

Three types of relational links are allowed between database tables’ (the primary storage unit of a relational database) which allow for relational databases to be used for even the most complex database operations.

The relational database overcomes the limitations found in the other database models already discussed. Some of the benefits of a relational model are:

– Quick access to data
– Easily implemented data integrity
– Utilizes a standard language (SQL)
– Easy to develop and modify applications

Object-oriented (OO) database:

An object-oriented database is very different from the typical database with which most people are familiar. The primary difference is that database “records” are accessed as properties of an object rather than as a group of related fields.

The benefits of an OO database are that modern application development is based upon objects, and the ability of objects to automatically inherit property settings from other objects.

Object-relational (OR) database:

The object-relational database model is a hybrid model that adapts the best concepts of the relational database model along with the best concepts of the OO database model. Though this model will probably become the industry standard in the future, there currently are no international standards available. This means that databases built using this model are proprietary and may have compatibility issues with other database implementations.

Summary:

The most used database model is the relational database model. Though this will gradually migrate towards the object-relational model, industry standards must be determined prior to widespread acceptance.

About User Lin