| File structure | ||||||||||||||||||||||||||||||||||||||
| A database
consists of a number of related files
(sometimes called tables).
A file consists of a number of related records. A record consists of a number of related fields. A field is a single data item consisting of a number of characters. Example 1 This table shows a small section of a file which contains details about school pupils:
The yellow section shows one record. The file has 6 records and each record has 4 fields (Number, Surname, Firstname and Form). The key field is used to uniquely identify a record. The key field in this example is 'Number'. No two records would have the same data in the key field. Fields may be of a number of different types :
|
||||||||||||||||||||||||||||||||||||||
|
When a database is created it is important that the same data is not
stored twice (this may lead to inconsistencies).
This is usually done by linking the
tables with relationships...using the key
field of one table as a field in another table.
|
||||||||||||||||||||||||||||||||||||||
| Data in a database can be accessed and used to produce reports. | A report may use data drawn from a number of different files. | |||||||||||||||||||||||||||||||||||||
| Exercise : File structure | ||||||||||||||||||||||||||||||||||||||
| A field is a single data item.
A record consists of a number of related . A file consists of a number of related . A database consists of a number of related . Example of part of a file :
This file has records. Each record has fields. The key field is .
|
||||||||||||||||||||||||||||||||||||||
| (Green indicates success) | ||||||||||||||||||||||||||||||||||||||