Database Application
Updated March 7th, 2023
We live in the information age. We collect data all the time for various reasons.Schools must keep records about teachers and students. Banks keep financial records about each customer. Hospitals keep medical records about each patient. Prison Officers keep records on each prisoner. This data must be organized. A powerful database application is the solution to managing large volumes of data.
This lecture on databases focuses on:
- What a databases is.
- File, Fields and Records
- Data Manager and Data Management.
- What is a DBMS?
- Relational Database
- Database Administrator
INTRODUCTION
If you have a little black book with names and addresses then you have a database. The most common database I can think of will be a telephone directory. Databases are designed to hold large volumes of data. They are designed to make retrieval of information easy yet they should be secure and reliable.
WHAT IS A DATABASE?
A database can be defined as a collection of related data, organized with a minimum of duplication of data items. The data is independent of the programs that use the data.
The data resources of an organization are usually stored in databases. It is impractical to store all the data for even relatively small organizations in one database. To overcome this problem organizations design database systems which integrate collections of databases along with users who share the databases.
To understand what a database is we should first examine in detail what a file is.
FILE
A file is a collection of related data stored under one reference or name in a computer. Another definition for a file is that it is a structure used to store data that are composed of related records.
FIELD
Each data item is placed in a field. When data is organized into columns and rows each column of data is called a field.
In a student file one can expect to find the following fields : Student Surname, Student First Name, Date of Birth, Gender, Address, Telephone number, Student Number. In the Student Surname field one will find only the surnames of students on file. In the telephone number field only student telephone numbers will be listed and so on.
It is important to note here that a field can hold data of only one data type. What then is a data type? You may ask. Well, take the Date of Birth field. It should accept only data that is in the date format. If someone should accidentally place a telephone number in the Date of Birth field then the database should reject the data as invalid for that field.
RECORD
A group of related fields form a record. When data is organized into columns and rows each row of data is called a record.
In the student file a student record is all the data held on one student. In a telephone directory, an individual's name, address and telephone number forms that persons record. Three records are listed in the table below. There are three fields in the following example. The field names are : Name , Address and Telephone. The entire second record is coloured for easy identification.
| Telephone Table | ||
| Name | Address | Telephone |
| Edwards Genevive | 294 Abdul Cir. Rd. | 628-5732 |
| Edwards George | 776 Brook Hollow Dr | 657-1314 |
| Edwards Glenn A | Parrylands Vge | 648-5187 |
MAIN FEATURES OF A DATABASE APPLICATION
- The ability to store large volumes of data.
- Many have their own particular database language.
- Typically, a database is capable of containing many files.
- Database applications allow users to search for, sort and relate the objects in files in various ways.
- Database programs generate reports.
- A Database application generally includes menus, data entry forms, ability to edit, delete records and help facilities.
Microsoft Access
MS Access database can be found on many personal computers. The data must be placed into tables. The tables in a database should be all related in some way.
A Microsoft Access database is made up of a number of objects. The main ones are : tables, queries, forms and reports. There are others such as macros and modules but lets focus of the first four. The most important object is the table object because all data is stored in tables. Without a table you really do not have a database.
Consider carefully each field that must be a part of the table before constructing each table. Planning the structure of your table on paper is very important. Decide on the name you will give to each field in the table and the type of data that is suitable for each field.
APPLICATIONS SUITABLE FOR A DATABASE
- Student records in a college - name, address, date of birth, student number
- Data held on items held in stock - name, part number, price, number in stock
- Books in a library - Title, category, author, ISBN
- Employee records - Employee number, Name, marital status, gender, date joined, date or birth, department
- Music Collection - Title of CD, Tunes, date purchased, where purchased, price, singer / musician
- Friends information - Name, nickname, date of birth, address, home phone, work phone, email address
MORE DATABASE FACTS
Types of Databases
A database system may employ one of four ways of organizing data :
- Hierarchical
- Network
- Object-oriented
- Relational - MS Access uses this model
- Document-oriented database program - MongoDB is an example
Hierarchical databases employ a tree structure in the ordering of data with a number of one to many relationships.
Network databases tend to be proprietary and run on a particular manufacturer's mainframes. Links are used to express relationships between different items of data.
Object-oriented databases differ form traditional databases in that an object consists of both data and programming instructions that act on the data. More traditional database structures store essentially text based data separate. Object-oriented databases accommodate audio, video, graphs and text data.
Relational databases stores data in tables. The tables are independent and can be dynamically linked by a user at program execution time. Data in hierarchical and network databases are pre-linked.
On some personal computers sometimes one can find a very simple type of database called a Flat-File Manager. This type of database is very limited and would allow reports to be generated from only one file at a time.
MongoDB is a free and open-source cross-platform document-oriented database program. Classified as a NoSQL database program
Test Yourself
Assignment
- What is a record?
- What is a field?
- What is a flat file manager?
- Name two fields you would expect to find in a patients database.
Lecturer:
|
The Tutor |
|