0% found this document useful (0 votes)
35 views17 pages

Year 11 DPR Note

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
35 views17 pages

Year 11 DPR Note

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 17

SCHEME OF WORKS FOR FIRST TERM

WEEKS TOPICS

1 Revision/Introduction to Database Management System

2 Data Processing Methods

3 Data Processing Techniques

4 Types of Data Models

5 Mid-Term Examination

6 Data Modelling

7 Mid-Term Break

8 Entity-Relationship Model

9 Relational Model I

10 Relational Model II

11 normalization

12 Revision

13 Examination

14 Collation of Results
INTRODUCTION TO DATABASE MANAGEMENT
DATABASE MANAGEMENT - Database management involves the process of creating,
monitoring, administration, and maintenance of the database and database groups in an
organization.
What is a Database? A database is a collection of information that is organized so that it can easily
be accessed, managed, and updated.
DATABASE MANAGEMENT SYSTEM(DBMS) is a set of programs that enables you to store,
modify, and extract information from a database. it also provides users with tools to add, delete,
access, modify and analyze data stored in one location.
EXAMPLES OF DBMS
1. MySQL
2. Microsoft Access
3. SQL Server
4. Oracle
5. RDBMS
6. dBase
7. FoxPro
BASIC TERMS IN DATABASE MANAGEMENT SYSTEM
CHARACTER- A character is the most basic element of data that can be observed and
manipulated. E.g. digit, letter, other special character (e.g., #, £ and?)
FIELD- A field contains an item of data; that is, a character, or group of characters that are related.
E.g. Name, Address, city etc.
RECORD- A record is composed of a group of related fields.
DATABASE FILE- A database file is defined as a collection of related records. A database file is
sometimes called a table.
KEY- in order to track and analyze data effectively, each record requires a unique identifier or what
is called a key.
COMPONENTS OR OBJECTS OF DATABASE
- Queries
- Report
- Forms
- Tables
- Macros
- Modules
QUERIES- A query is an access object that enables you to view data from one or more tables in a
specified order.
TYPES OF QUERIES
There are three main types of queries:
1. Select
2. Action (Delete, Append, Update and Make-table)
3. Cross tab
The most common type is a SELECT QUERY
SELECT QUERY- it is used to retrieve data from a table or multiple table
REPORT
A report consists of information that is pulled from tables. A report is a read-only view of the
inputted data.
FORM
A form is generally used to add/update/delete records. Forms are created to enable user interaction
with the database
TABLE
A table can be defined as an organized collection of related records
DATATYPES
- Memo
- Text
- Date & Time
- Currency
- Number
USE OF MS ACCESS AND SPREADSHEET FOR DATABASE
Microsoft Access is a database software package. A database is an organized collection of records.
Telephone and address books are examples of paper databases. With Access, you can create a
computerized database.
- Access can be used to organize and keep a record of personal finances, information
about students or staff
- It can also be used to make a music library where you can store a large number of songs
- Access is a computer program that is used to store, manage, view and publish
information or data.
Spreadsheet is used for creating results of calculation based on figures that are put into the
spreadsheet. Spreadsheet is used when you want to do the following:
- You want to crunch numbers and perform automatic calculation
- You want to track a simple list of data
LOADING MS ACCESS 2007
- Click on the start button
- Point to all program
- Point or click on Office Suite
- Select MS Access 2007
EXIT MS ACCESS 2007
- Click on the quick Access toolbar
- Select Exit Access
USING TABLE WIZARD
MS Access table wizard provides an easy way to create tables. It provides various table templates to
create business and personnel tables.
The following procedure is used to create a table using table wizard.
- Open Database window
- Click table (New Table) in the object bar
- Double-click create a table by using wizard. The table wizard will start.
Note: Table wizard has been removed in Access 2007. It has been replaced with five table
templates. (contacts, tasks, issue, events, assets).
DATA PROCESSING METHOD
METHODS OF DATA PROCESSING- The three (3) basic methods of data processing
are:
- Manual Method
- Mechanical Method
- Electronic Method
MANUAL METHOD: This involves the use of pens, pencils, worksheet, journals and files
by one or more persons in processing data. It is very cheap to implement but it is
cumbersome, tiresome, boring, frustrating and time consuming. The result is also affected
by human errors.
Advantages of manual method
1. Easy to get the instrument to use
2. It is very cheap to implement
Disadvantages of manual method
1. It is cumbersome
2. It is time consuming
3. The result can be affected by human errors
MECHANICAL METHOD: This is when machine such as typewriter accounting
machines and calculator are used for processing data. Data cannot be processed
continuously without human assistance. It is also difficult to produce large quantities of
information on regular and timely basis. It involves operation that are noisy, paper
consuming and subject to human errors.
Advantages of mechanical method
1. It is faster than manual processing of data
2. It is more accurate than manual method
Disadvantages of mechanical method
1. It is difficult to produce large quantities of information on regular and timely basis
2. It is subject to human errors
ELECTRONIC/AUTOMATIC METHOD: This is when data processing is carried out
using electronic digital system. The principal digital machine used for data processing is
computer. Electronic data processing is the use of electronic aids (computer) to process data.
Its operation does not involve noise and it has a memory for storage. With the aid of
computer, accurate, reliable and significant amount of information can be obtained at high
speed.
Advantages of electronic method
1. Its operation does not involve noise
2. It has a memory for storage of data
3. It is accurate and reliable
Disadvantages of electronic method
1. It is expensive
2. It might lead to error if the system is not properly handled or maintained
Factors that determine the method of data processing
1. Size of data to be processed
2. Type of business
3. Time at which information is required
4. Link between application
5. Cost of method
6. Accuracy of method
DATA PROCESSING TECHNIQUES
Batch Processing is the execution of a series of jobs in a program on a computer without manual
intervention (non-intervention). Batch processing dates to the late 19th century, in the processing of
data stored on desks of punch card by unit record equipment, specifically the tabulating machine by
Herman Hollerith, used for 1890 United States census.
In data transmission, Batch processing is used for very large files or where a fast response
time is not critical. The files to be transmitted are gathered over a period and then sent together as a
batch.
Advantages of Batch Processing
1. Repeated jobs are done fast in batch systems without user interaction
2. Batch system can work offline so it makes less stress on processor
3. The batch system can manage large, repeated work easily
Disadvantages of batch processing
1. It is difficult to debug batch system
2. Batch systems are sometime costly
3. If some job takes too much time i.e. if error occurs in job then other jobs will wait for
unknown time
Online Processing: is the term used to describe when a user is connected to a computer or network
(they are logged in) and process the data files at the same time as using the input, output and
storage devices. This method at time known as direct or random-access processing. Under this
method the job received by the system is processed at same time of receiving. This can be
considered and often mixed with real-time processing. This system features: random and rapid
input of transaction and user defied/demanded direct access to databases/content when needed.
Advantages of Online Processing
1. Easy to use to do shopping online
2. The systems have quick response time
3. Usage of credit cards is also handled by these systems
4. Online banks nowadays use online processing systems for money transaction
Disadvantages of Online Processing
1. There occur millions of requests to banks at a time which is difficult to handle
2. Online processing involves lot of staff to maintain inventory
3. Some issue also get involves during creation of new accounts by visitors
Multi-Processing: is the capability of a computer to multitask, or execute more than one program
or process at the same time. Examples include processing data and instructions in computer,
laptops, mobile phone etc. Multiprocessing makes use of CPUs (more than one CPU). The task or
sets of operations are divided between CPUs available simultaneously thus increasing efficiency
and throughput.
Advantages of Multiprocessing
1. Increase throughput
2. Economy of scale
3. Increased reliability
Disadvantages of Multiprocessing
1. If one processor faults then it will affect the speed of other
2. Multiprocessor system are expensive
3. Complex OS is required
4. Large main memory required
Real-Time Processing: As the name suggests thus method is used for carrying out real-time
processing. This is required where the results are displayed immediately or in lowest time possible.
The data fed to the software is used almost instantaneously for processing purpose. The nature of
processing of this type of data processing requires use of internet connection and data is stored/used
online. This method is costly than batch processing as the hardware and software capabilities are
better. Example includes banking system, tickets booking for flights, trains, movie tickets, rental
agencies etc.
Advantages of Real-Time Processing
1. Real time processing provides immediate responses to user inquiries
2. Real time processing is particularly important for applications where a high frequency to
changes must be made to a file during a short time to keep it updated
3. Only the specific records affected by transactions or inquiries need to be processed and
several database can be processed or update concurrently
Disadvantages of Real-Time Processing
1. Organization with critical OLAP application have to pay a high-cost premium for the
security of fault tolerant for document
2. Because of the online, direct access nature of real time processing networks, special
precaution must be taken to protect the content of database
Time Sharing Processing: Time based used of CPU is the core of this data processing type. The
single CPU is used by multiple users. All Users share same CPU but the time allocated to all users
might differ. The processing takes place at different intervals for different users as per allocated
time. Since multiple user can use this type it is also referred as multi access system.
Advantages of Time Sharing
1. High CPU efficiency
2. Each user gets CPU time
Disadvantages of Time Sharing
1. Complex OS (operating system) require
TYPES OF DATA MODELS
Data Modeling is a conceptual representation of data structures (tables) required for a database and
is very powerful in expressing and communicating the business requirements. This is the process of
structuring and organizing data.
CONCEPT OF DATA MODELING
The concept of data modelling can be better understood if it is used to compare the
development cycle of a data model to the construction of a house. For example company ABC is
planning to build a guest house (database) and it calls the building architect (data modeler) and
projects its building requirement (business requirement). Building architect (data Modeler)
develops the plan (data model) and gives it to company ABC. Finally, Company ABC calls civil
engineers (DBA) to construct the guest house (database). Data model represent a real world
situation about which data is to be collected and stored in a database. The term data model actually
refers to two very different things: a description of data structure and the way data are organized
(data organization)
Approaches in data modeling
Approaches or levels to data modeling are:
1. Conceptual data modeling
2. Logical data modeling
3. Physical data modeling
Conceptual data modeling
This is the first stage of database design it identifies the highest-level of relationships
between the different entities. In this approach the following steps are taken:
- Specify the important entities and the relationship among them
- No attribute is specified
- No primary key is specified
Logical model
This is the second stage of database design. Here data is detailed described without regard to
the physical implementation into database. Following steps are taken:
- Specify primary keys for all entities
- Find the relationships between different entities
- Find all attributes for each entity
- Resolve many-to-many relationships
Physical data model
This is the transformation of the logical database into the actual database. Physical data
model represents how the model will be built in the database. A physical database model shows all
table structures, including column name, column data types, column constraints, primary keys,
foreign physical data model design are follows:
- Convert entities into tables
- Convert relationships into foreign keys
- Convert attribute into columns
- Modify the physical data model based on physical constraints requirements

Components of a Data Model


The data model has two outputs. The first is an Entity-Relationship diagram which represents the
data structure in a pictorial form. It is a valuable tool to communicate the model to the end-user.
The second component is a Basic Concept in DBMS data document. This is a document that
describes in detail the data objects, relationships, and rules required by the database.
A data model can also include components called links that represent relationship between different
elements of data. A data model consists of the following components: Data sources, Data
types, Data items, Links, and Event sources
Types of Data model
Among the various types of data models are:
1. Flat file data model
2. Hierarchical data model
3. Network data model
4. Relational data model
5. Entity relational model
6. Object oriented data model
7. Star schema

Flat file data model


The flat (or table) model consists of a single, two-dimensional array of data elements where
all members of a given columns are assumed to be identical values and all members row are
assumed to be related to one another.
Hierarchical Model
Hierarchical relationship is one where each entity at a lower level of the hierarchy is related
to only one type of entity at a higher level of the hierarchy (a higher level entity can be linked to
two or more lower level “Child” entries). In this model, data is organized into a tree-like structure.,
implying a single upward link in each record to describe the nesting, and a sort field to keep the
records in a particular order in each same-level list. The first database systems developed were
hierarchical.
Advantages
1. It promotes data sharing
2. Database security is provided and enforced by DBMS
3. It is efficient with 1:M relationship
Disadvantages
1. Complex implementation requires knowledge of physical data storage
2. Modification is very difficult to implement when organization’s data needs change.
Network Model
A network relationship is one in which an entity at a lower level can be linked to two or
more entities at a higher level. This model organizes data using two fundamental constructs called
records sets. Records contain fields, and sets define one-to-many relationships between records: one
owner, many members. This is the next type of data model developed after hierarchical model.
Advantages
1. It handles more relation type such as M: N and multi-parent
2. Data owner/member promotes data integrity
3. Data access i.e. more flexible
Disadvantages
1. System complexity limits efficiency
2. Structural changes require changes in all application program.
Relational Model
The relational database is perceived as a collection of tables. Each table consists of a series
of row/column intersections.
Advantages
1. Structural independence is promoted by the use of independent tables.
2. Changes in a table structure do not affect data access or applied program
3. Improved conceptual simplicity.
Disadvantages
1. The RDMS requires substantial hardware and system software overhead
2. Possibility of poor – design and implementation
3. There is no data definition or data manipulation language.
OBJECT-RELATIONAL MODEL
Objects are abstractions of real-world entities or events. An object is described by its factual
content. An object includes information about relationship between the facts within the object, as
well as with other objects. An object is a self-contained building block for autonomous structure.
Advanatages
1. Adds semantic content
2. Visual presentation includes semantic content
3. Database integrity
Disadvantages
1. Complex navigational data access
2. High system overheads slows transactions
3. Lack of OODM standards
STAR SCHEMA
Is the simplest style of data warehouse schema. The star schema consisted of a few “fact tables”
(possibly only one, justifying the name) referencing any number of “dimension tables”.
ENTITY-RELATIONSHIP MODEL
Entity-Relationship is a graphical representation of entities and their relationships to each other.
Components of Entity-Relationship
Entity relationship diagrams have three different components:
1. Entities
2. Attributes
3. Relationships
An entity is defined as a single distinguishable business object such as a person, place, thing, event
or concept, part of a group of similar objects relevant to an organization about which the
organization is interested in storing and using information.
The purpose of a database is to store information about these objects.
Attributes are properties (characteristics) of the entity. It is these attributes that will
correspond to the field (columns) in tables of the database.
A relationship is an association between entity types.
Cardinality
The cardinality defines the relationship between the entities in terms of numbers.
Types of relationship (cardinality)
1. One-to-One (I: I) relationship
2. One-to-Many (I: M) relationship
3. Many-to-Many (M: N) relationship
RELATIONAL MODEL
The relational model (RM) for database management is an approach to manage data using a
structure and language consistent with first – order predict logic, first described by
Edgar.F.Codd in 1969. A model in which all data is represented in terms of tuples, grouped
into relations.
Terms in Relational Database
A relation is a table
The columns (fields) in the table identify the attributes such as names, age and so on.
A tuple is a single row of a table, which contains a single record for the relation.
Null value: A field with no value. Null value is different zero or space(s) value. It is a field that
is left blank during record creation
Constraints: these are used to limit the types of data that can go into a table or a particular
field
Unique key: Prevents duplicate data.
Relational Database Management System(RDBMS) is the basic for SQL and modern
database system such as My SQL, Oracle, DB2, MS Access etc.

SQL (STRUCTURED QUERY LANGUAGE)


SQL is the programming language used for managing data in relational database
management system (RDBMS).
Types of SQL commands
The main categories:
DDL (Data Definition Language)
DML (Data Manipulation Language)
DCL (Data Control Language)
DQL (Data Query Language)
DDL (Data Definition Language)
DDL: is the part of SQL that allows a database user to create and restructure database
objects. The main DDL commands are : CREATE TABLE, ALTER TABLE, DROP TABLE,
CREATE INDEX, ALTER INDEX, and DROP INDEX.
DML (Data Manipulation Language)
DML: is the part of SQL used to manipulate data within objects of a relational database.
They are SELECT, INSERT, UPDATE, and DELETE command

DCL (Data Control Language)


GRANT: Gives a privilege to user
REVOKE: Takes back privileges granted from user
DQL (Data Query Language)
SELECT: Retrieves certain records from one or more tables
CREATING DATABASE USING SQL
The SQL CREATE DATABASE statement is used to create new SQL database.
Syntax:
Basic syntax of CREATE DATABASE statement is as follows:
CREATE DATABASE DatabaseName;
Always database name should be unique within the RDBMS
Example: If you want to create new database <school>, then CREATE DATABASE
statement would be as follows:
SQL>CREATE DATABASE School;
SQL>SHOW DATABASE( it help you if you want to check the database)
NORMALIZATION
Normalization is the process of organizing the columns (Attributes) and table (relations) of a
relational database to reduce (eliminate) data redundancy and improve data integrity.
Concept of Normalization
Normalization is accomplished through applying some formal rules either by a process of
synthesis or decomposition
Synthesis creates a normalized database design based on a known set of dependences
Decomposition takes an existing (insufficiently normalized) database design and
improves it based on the known set of dependencies. Edgar .F.Codd, invented the relational
model (RM) and the concept of Normalisation.
Normalisation involves arranging attributes in table based on dependencies between
attributes, ensuring that dependencies are properly enforced by database integrity
constraints.
Examples of Normal Forms
1. First normal form (1NF)
2. Second normal form (2NF)
3. Third normal form (3NF)
4. Boyce-codd normal form (BCNF)
In formally, a relational database table is often described as normalized if it meets third normal
form most 3NF table are free of insertion, update and deletion anomalies.
Reasons for Normalisation
If normalization is not addressed, it becomes difficult to handle and update the database
without facing data loss insertion, updating and deletion anomalies are very frequent if database is
not normalized. Other reasons are:
1. To put data into the form that is more able to accurately accommodate changes
2. To avoid certain updating “anomalies”
3. To facilitate the enforcement of data constraints
4. To avoid unnecessary coding
Advantages of Normalisation
1. Greater overall database organization will be gained
2. The amount of unnecessary redundant data is reduced
3. Data integrity is easily maintained within the database
4. The database and application design process are much more flexible
5. Security is easier to manage
Disadvantage of Normalisation
1. The result may be complicated when joining multiple normalized tables
Types of keys in Relational model
1. Primary key
2. Foreign key
3. Candidate key
4. Composite key
5. Alternate key
6. Super key

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy