Section 7.2: Bullet Text
Chapter Contents | View Full Text | View Bullet Text

The Database Approach to Data Management

Database technology eliminates many of the problems of traditional file organization by organizing data so that they can efficiently serve many applications and different groups at the same time. Instead of storing data in separate files for each application, a database management system (DBMS) allows individual business applications to extract information from a central source without having to create separate files or data definitions in their computer programs. [Figure 7-4]




Figure 7-4: The contemporary database environment

A single human resources database serves multiple applications and also enables a corporation to easily draw together all the information for various applications. The database management system acts as the interface between the application programs and the data.

          A DBMS has three components: a data definition language; a data manipulation language; and a data dictionary. The most important difference between a DBMS and traditional file organization is that the DBMS separates the logical and physical views of data, relieving the programmer or end user from the task of understanding where and how the data are actually stored. The logical view presents data as they would be seen by end users, whereas the physical view shows how data are actually organized and structured on physical storage media. The logical definition of the entire database showing all the data elements and their relationships is called the conceptual schema. Structured query language (SQL) is the principal data manipulation language for relational DBMS. [Figure 7-5]


Figure 7-5: Sample data dictionary report
The sample data dictionary report for a human resources database provides helpful information, such as the size of the data element, which programs and reports use it, and which group in the organization is the owner responsible for maintaining it. The report also shows some of the other names that the organization uses for this piece of data.

          A DBMS can simplify an organization's information system environment by providing central management of data, access, utilization, and security. Data redundancy and inconsistency can be reduced by eliminating all of the isolated files in which the same data elements are repeated. Data confusion can be eliminated by providing central control of data creation and definitions.

          Program-data dependence can be reduced by separating the logical view of data from the physical arrangement of data. Flexibility of information systems can be greatly enhanced by permitting rapid and inexpensive ad hoc queries of very large pools of information. Also, with a DBMS, access and availability of information can be significantly increased.

          Conventional DBMS keep track of entities, attributes, and relationships using one of three logical database models: relational, hierarchical, and network and object-oriented. Each logical model has certain processing advantages and disadvantages.

          The relational database model represents data as two-dimensional tables called relations and can depict many-to-many relationships. It can relate data stored in one table to data in another as long as the two tables share a common data element. Relational DBMS provide greater flexibility than the other database models in regard to ad hoc queries, power to combine information from different sources, simplicity of design and maintenance, and the ability to add new data and records without disturbing existing programs. The three basic operations in a relational database are select, project, and join. [Figure 7-6, Figure 7-7]





Figure 7-6: The relational data model

Each table is a relation, each row is a tuple representing a record, and each column is an attribute representing a field. These relations can easily be combined and extracted to access data and produce reports, provided that any two share a common data element. In this example, the PART and SUPPLIER files share the data element Supplier_Number.





Figure 7-7: The three basic operations of a relational DBMS
The select, project, and join operations allow data from two different tables to be combined and only selected attributes to be displayed.

          Hierarchical and network database models are extremely efficient at processing large structured routine requests. The hierarchical database model is useful for depicting one-to-many relationships. The network database model can depict many-to-many relationships. However, both network and hierarchical database models lack flexibility and are inappropriate when non-routine or ad hoc information is needed. Both hierarchical and network systems are programming-intensive, time-consuming, difficult to install, and difficult to fix if design errors occur. [Figure 7-8, Figure 7-9]




Figure 7-8: A hierarchical database for a human resources system

The hierarchical database model looks like an organizational chart or a family tree. It has a single root segment (Employee) connected to lower level segments (Compensation, Job Assignments, and Benefits). Each subordinate segment, in turn, may connect to other subordinate segments. Here, Compensation connects to Performance Ratings and Salary History. Benefits connects to Pension, Life Insurance, and Health. Each subordinate segment is the child of the segment directly above it.





Figure 7-9: The network data model

This illustration of a network data model showing the relationship the students in a university have to the courses they take represents an example of logical many-to-many relationships.

          Since conventional DBMS are not well-suited to handling graphics or multimedia applications, object-oriented databases have been developed. An object-oriented DBMS (OODBMS) stores data and procedures as objects that can be retrieved and shared. Although OODBMS can store more complex information than relational DBMS, they are relatively slow for processing large numbers of transactions. Hybrid object-relational DBMS combine the capabilities of both object-oriented and relational DBMS.