Download presentation
Presentation is loading. Please wait.
1
Database Design Concepts Info 1408 Lecture 2 An Introduction to Data Storage
2
Lecture 2- Data Storage Objectives of lecture Introduce the purposes of data processing Explain the terms of fields, records and files Explain how these are organised in traditional data processing systems Introduce how Database offers a solution to some of the problems with traditional data processing systems
3
Information System Information systems process data What is data? A definition Often computerised but can be manual
4
Typical activities of an Information System Getting data into the system ( ) Storing data ( ) Sorting data ( ) Finding data ( ) Processing data into a usable data ( ) Changing data ( ) Checking data is correct and reasonable (Validation and verification) Calculation
5
To be able to carryout these processes we need to organise our data The smallest unit of usable data is known as a field or
6
Properties of fields Each field will have A name A description A Size A type A value of a variable A range of acceptable values
7
Example Date of Birth Name- date of birth Description- the date the person was born Size- 10 characters (dd/mm/yyyy) Type- date Value of a variable This varies for each person but each person will have a value for date of birth which is stored in that field Range- the date should be before today’s date
8
Complete the following table NameStudent nameAddress Description Size Type Range
9
Records Fields that describe an entity are combined to make a record For example Student name, student address and student telephone number all describe a student- they are combined in a student record to record facts about a student Each individual student will have a record- made up of the same fields
10
Records continued When designing a record it is important to decide which fields are required to carryout all the processing requirements of the information system A record can have fields (fields which must have a value) And fields ( some instances may not have a value) Eg all students must have a name and date of birth but not all of them will have a mobile phone number
11
Files Records which describe the same type of entity are grouped together into a file For example all the individual student records will be kept together in a file- this will usually have a name that describes what the records hold information about – in this case the student file seems an appropriate name
12
An information system needs to store all of these files (on disc) This is no different to a filing cabinet we need to store the files in a way that makes it easy for us to find any information as easily as possible.
13
Imagine using a filling cabinet to store student registration forms and all the forms have been placed in a filing cabinet and you need to know if a student called John has been registered properly We make it easy to find information by sorting all the records in a file in a particular order.
14
File organisation- traditional Serial in the order they were added to the file Sequential- in a specific order eg Indexed sequential – In a specific order but with an index to help you locate something specific ( index is like a book index it tell you where to go exactly on the disc) Random access uses a key (or ) which tells you where to find the record.
15
The problem with this approach is that you have to think how you want to access your information and choose a file organisation to do this. This is often called a system. As different users may want to do different things there may be situations where
16
Different users have different versions of the same file Example Bank customer changes their address The customer has a record for their current account, savings account, bank loan and the marketing file all of which record the customers address. How can we be sure we have changed it on every file Examples of junk mail etc show very often things don’t get changed on all files Even worse what if you find yourself with two addresses for the same customer- which is correct ? The other problem with this you have a lot of duplicate data and are therefore wasting a lot space and money maintaining it.
17
Problems in doing new activities. For example recording e-mail addresses for customers ( you didn’t before) As programmes will need to know how a file is structured any change to the file means every programme which uses that file will need to be changed. This takes a great deal of time and costs a lot of money
18
How do we reduce these problems In recent years many companies have used Databases to remove these problems (and many others) A database provides a method of storage which enables all the users to share the data ( removes the and problems) in a way that allows the structure of the data to be changed relatively easily (for example add new fields)
19
This means it is easier to use but it makes the design more difficult. It is important to design a database that meets everyone's needs We will be learning how to identify all the data requirements of the different users and organise it in a way which allows everyone to share the same data We will identify the attributes required- (which is the database name for a field) Into tables ( which is the database name for a file)
20
Summary Information systems store data in files- In database system this known as a table. A file is made up of records which describe each instance of interest using the same fields. A database system calls a record a row, and a field is known as an attribute. Files are organised in a way that makes it easy for a user to find a specific record but this may not be suitable for all users. Databases give us a way of being able to find data easily and quickly.
21
References Databases Demystified by Andy Oppel
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.