Download SECTION 5

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

Entity–attribute–value model wikipedia , lookup

Extensible Storage Engine wikipedia , lookup

Database wikipedia , lookup

Clusterpoint wikipedia , lookup

Functional Database Model wikipedia , lookup

Relational model wikipedia , lookup

Database model wikipedia , lookup

Transcript
Zayna Khan
10/03/2010
SECTION 5
Data Types
Data Type
Example
Boolean
Text
Integer
Real
Date
Yes/No
Andy Conda
16
1.456
25/10/2010
Term
File
Record
Definition
A set of related records (either written or electronic) kept together
The data shown is a group of related data items - all of the data
refers to one student: Zayna Khan.
A group of data like this is called a record.
In single record, we can see that it is made up of a number of
different data items. The individual items are referred to as fields
In most databases, one of the fields is used to uniquely identify each
record (the value of this field must be different for each record). This
special field is called the key field.
Field
Key Field
Flat-file versus Relational Databases
Flat-file database
Relational database
1 table
Several tables that are linked by foreignkey relationships
Less data redundancy as same
information is not repeated twice
Same piece of information may be
repeated lots of times, Data redundancy
very common
Data inconsistency quite likely to occur
Data inconsistency is impossible
Zayna Khan
10/03/2010
With reference to “primary key”, “foreign key” and “relationship” explain
what is meant by “data redundancy” and “data consistency” and explain how
relational databases address the problems associated with each (6)
A flat-file database consists of one table. A relational database comprises a number of
tables that are linked by foreign-key relationships.
In a flat-file database the same piece of information may be repeated lots of times.
However, a relational database would only store it once, in a separate product table.
The fact that a flat-file database stores the same information several times is an
example of data redundancy.
Data redundancy can also lead to data inconsistency, for example if a new row is
created in a flat-file database and the product's price is entered wrongly. Relational
databases avoid data consistency problems by only storing each piece of information
once. It is still possible to enter a "wrong" price for a product, but it is impossible for
the price to be inconsistent if the database is designed properly.
Define the following:
Analogue data
Analogue data can be any value within a
defined range. For example, an analogue
sound level can have any loudness
between zero and the maximum
recorded and any frequencies between
the highest and lowest recorded. A
traditional watch face is an analogue
output and a vinyl record is an example
of an analogue storage device.
Digital data
Digital data is made up of the two binary
numbers, 0 and 1. Text, music, images,
video etc all have to be converted into
digital data (digitised) before they can be
processed and stored by a computer.
Digital data is transferred as a stream of
on/off or high/low pulses and can have
many different forms such as electrical,
light, radio, infrared, microwave, etc.
These pulses have only two states
representing the two binary numbers. In
an electrical digital signal for example,
the voltage pulses are either on,
representing a 1, or off , representing a 0.
Give four reasons why data needs to be converted from Analogue to Digital
Digital data is easier to communicate between computers because it is already in a
format that can be processed
Digital data is faster to communicate between computers
Analogue data cannot be processed by a computer so it must be converted into
digital data by an interface.
I can’t think of another one