Docsity

Understanding Databases: Organization, Benefits, and Types - Prof. Brian O. Wright, Study notes of Computer Science

Toggle sidebar
bg1
Introduction to Databases
Databases are used to store electronic information. In order to construct a
database, you need to understand how data can and should be organized. In order
to be able to use the data to obtain valuable information, you also have to
understand how to find it in the database. Before we begin building and using our
database, we will first discuss the benefits of using databases, components of
database management systems, different ways to organize information, and types
of databases.
We refer to an electronic database as secondary storage. This means that the
information is contained or housed in some sort of media such as magnetic disk (i.e.
hard drive) or tape. Today’s fast access hard drives with large storage capacities
make databases extremely useful for organizations to keep track of large amounts
of data.
Benefits of Databases
Without a central database, an organization may need multiple files on the same
subject or person. Duplicate information can cause a lack of data integrity where
not all files contain the same information; in addition there would be a lot of wasted
storage space. Think about a University student records system. When you
applied to USA, your information was entered into a central database by the
Admissions office. Those same records are accessible by the Registrar, the
colleges and departments within the University, as well as other organizations. If,
for example, you change your address, that information only needs to be changed
in one central location and all organizations and departments can get access to the
updated information. The many advantages of databases include:
1) Data Sharing – information in one department or organization can be
readily shared with others.
2) Security – users can be given passwords and/or access only to the
specific information they should have, while storing all of the information
only once in the database.
3) Data Redundancy – fewer files are necessary; the data is stored only
once and in one location. This reduces the storage space needed.
4) Data Integrity – Changes made in the file will update all occurrences of
the information.
Database Management Systems
A Database Management System (DBMS) is special software that allows you to
create, modify, and gain access to a database. Many are created specifically for
microcomputers and others are created for minicomputers and mainframes, used by
larger organizations.
1 of 5
pf3
pf4
pf5

Partial preview of the text

Download Understanding Databases: Organization, Benefits, and Types - Prof. Brian O. Wright and more Study notes Computer Science in PDF only on Docsity!

Introduction to Databases

Databases are used to store electronic information. In order to construct a database, you need to understand how data can and should be organized. In order to be able to use the data to obtain valuable information, you also have to understand how to find it in the database. Before we begin building and using our database, we will first discuss the benefits of using databases, components of database management systems, different ways to organize information, and types of databases. We refer to an electronic database as secondary storage. This means that the information is contained or housed in some sort of media such as magnetic disk (i.e. hard drive) or tape. Today’s fast access hard drives with large storage capacities make databases extremely useful for organizations to keep track of large amounts of data. Benefits of Databases Without a central database, an organization may need multiple files on the same subject or person. Duplicate information can cause a lack of data integrity where not all files contain the same information; in addition there would be a lot of wasted storage space. Think about a University student records system. When you applied to USA, your information was entered into a central database by the Admissions office. Those same records are accessible by the Registrar, the colleges and departments within the University, as well as other organizations. If, for example, you change your address, that information only needs to be changed in one central location and all organizations and departments can get access to the updated information. The many advantages of databases include:

  1. Data Sharing – information in one department or organization can be readily shared with others.
  2. Security – users can be given passwords and/or access only to the specific information they should have, while storing all of the information only once in the database.
  3. Data Redundancy – fewer files are necessary; the data is stored only once and in one location. This reduces the storage space needed.
  4. Data Integrity – Changes made in the file will update all occurrences of the information. Database Management Systems A Database Management System (DBMS) is special software that allows you to create, modify, and gain access to a database. Many are created specifically for microcomputers and others are created for minicomputers and mainframes, used by larger organizations.

A data dictionary contains a description of the structure of the data used in the database. For a particular record, it defines the field names, what type of data can go into the field, the size of the field, and also defines which field is the key field. The part of the DBMS that allows access to the information in the database is the query language. The most widely used query language is SQL (structured query language). These commands allow us to view or extract information based on certain criteria. Later we will see how useful queries can be to extract meaningful information from the database which can also be used in reports. Database Organization The purpose of a database is to integrate individual items of data. This data can be organized in different ways to best suit the users’ needs. The four most common types of database formats are:

  1. Hierarchical Database
  2. Network Database
  3. Relational Database
  4. Object Oriented Database Hierarchical Databases: Hierarchical databases are structured in nodes (tree like structure). Each child node has one and only one parent node (a parent may have more than one child node). We refer to this as a 1-to-many relationship. To find information in related nodes, the system must progress top down to traverse fields. To find information, you must start at the top with a parent node and trace down the tree. Pointers connect parent nodes to child nodes. Example: Airlines Flight Reservation System (simplified view) Departure City à Los Angeles Many Arrival Cities à Chicago, New York, Cleveland, Boston Flight Number (to NY) à 110 139 215 Passenger (flight 139) à Smith, Jones, Adams, Howell

Network databases can be very efficient and faster than hierarchical databases. Also, they have considerably less data redundancy. However, they have low flexibility and more pointers. The number of pointers increases rapidly, which makes it much more complicated to maintain and operate. Relational Databases : Relational databases are the most flexible. This database format is not hierarchical in nature. Tables are made up of columns and rows: columns correspond to fields; rows correspond to records. Related tables can be linked together through Common Data Elements (keys, foreign keys). We will discuss these in more detail later. Example: Registered Drivers Table 1 – Owner’s Table Name (foreign key from Table 2) License Plate Number Make Model Color Table 2 – Address Table Name Driver’s License Number Street Address City State Zip Table 3 – Citation Table Driver’s License Number (foreign key from Table 2) Code Violation Courses Student Teacher

Relational databases are the most popular in use today since the design makes it simple to add, delete, and edit records and database elements. Maintenance is simpler since there are no pointers to maintain. In this database, you can relate data in one field in one table to another field in another table easily. Its flexibility is one of the major advantages; ad hoc queries can combine data from different tables. However, relational databases can be slower since information retrieval may require multiple accesses to the data. This model also requires some data redundancy in order to be more efficient; the same data must appear in multiple tables to link the tables (common data elements as mentioned earlier). Upon updates, any redundant data that occurs in multiple places must be updated in all occurrences. Object Oriented Databases: Object oriented databases handle unstructured data such as photographs, graphics, audio, video, etc. Object oriented databases keep track of objects – both data and the action that can be taken on the object. Types of Databases: Databases can also be classified into several different types of databases based on their use:  Individual – collection of files primarily used by just one person  Company/Shared – databases that can be used by multiple users, shared through local area networks  Distributed – data for the database is stored in multiple locations with access through communication networks  Proprietary – an enormous database developed to cover particular subject areas; usually offers access to people for a fee – databanks. In our next lecture, we will further explore databases and introduce Access. Owner Citation Address