teach-ict.com logo

THE education site for computer science and ICT

Structured Query Language (SQL)

2. Parts of a database

A database is made up of one or more tables.

Like this:

database table

Each table should be given a relevant name. The table above is named 'Characters' because it contains well known cartoon or comic characters.

 

database field

Each column in a table is called a field and contains information about a particular item of data. Each field should be given a relevant name, for instance the field called 'city' contains a city name. A field is always set to a certain data type such as

  • numeric types: integer, float, real
  • boolean
  • character
  • string
  • Date and time
  • binary
  • Other e.g. blob

 

Each row in a table is called a record. Here is a single record from the table above

database record

A record is made up of collection of fields related to a single item.

In short:

  • Each piece of information is entered into a 'field'
  • Related fields are organised into records
  • Related records are placed into tables
  • Related tables are collected into a database

Challenge see if you can find out one extra fact on this topic that we haven't already told you

Click on this link: Parts of a database