Coursework Explorer Home > Ks3 > Year10 > Little Theatre Company > Task 4

LTC - Task 4 - Helpers Database Pt.2


  • Learning Intentions
  • Task 4 Pt.1a
  • Task 4 Pt.1b
  • Task 4 Pt.2
  • Levels

TaskFor this task you will:

  • learn all about data types
  • plan the table you are going to produce using given fields
  • fill the table with data
  • print out various pieces of information by using sort and filter techniques

Task 4a - Data types

As you know data is stored in records in a database. Each individual piece of data contained in the record is stored in a field. When storing data in a field you need to know what 'data type' it should be stored as.

In the table below you can see the data types available in Microsoft Access. This can also be seen in a Word document. Click here to view the Word document.

TEXT

Text or combinations of text and numbers, as well as numbers that don’t require calculations, such as telephone numbers.

Up to 255 characters in length.

MEMO

Lengthy text or combinations of text and numbers.

Up to 65,535 characters in length.

NUMBER

Used for storing numbers that can be used in calculations.

DATE/TIME

Used for storing dates and times

CURRENCY

Used for storing monetary values and numeric data used in calculations, using from 1 to 4 decimal places

AUTO NUMBER

These are numbers allocated by the computer.  The numbers are usually allocated in sequence.
When using AutoNumber, the number given will always be unique (it will never be repeated)

YES/NO

Used for storing data such as Yes/No, True/False

OLE OBJECT

An object (such as Microsoft Excel spreadsheet, a Microsoft Word document, graphics, sounds or other binary data) linked to or embedded in a MS Access table

HYPERLINK

Text or combinations of text and numbers stored as text and used as a hyperlink address.

LOOKUP WIZARD

Creates a field that allows you to choose a value from another table, or from a list of values by using a list box or combo box.

Task 4b (Task 4 - Part1) - Choosing the right data type

For task 4 part 1 you have to create a database for all the cast members. You must include the fields below. For each field you need to decide the correct data type.

  • Surname - Data Type?

  • Forename - Data Type?

  • Gender - Data Type?

  • Year - Data Type?

  • Address - Data Type?

  • Postcode - Data Type?

  • Tel_no - Data Type?

  • Part - Data Type?

  • Costume (Hired or Made) - Data type?

Parts should include Joseph, his 11 brothers, his mother and father, Pharaoh, Potiphar and his wife, jailer, baker and butler. (Use the names of pupils in your class and/or any others you wish. Decide whether or not a costume needs to be hired or made). You play the part of Joseph.

Task 4c - More on data types

There are some important facts to note about data types:

  1. A text field will store any combination of text and numbers. This is called 'Alphanumeric'.

  2. When storing a telephone number you must store it as TEXT. This is because all telephone numbers begin with '0' (zero) .If you store a number with a zero at the front as the data type 'number' the zero will be dropped.

    Therefore if you want to store the telephone number '02840645677' in a number field you will get '2840645677'. If stored in a field with data type of 'text' then it will remain intact.

  3. As you can see from the field lists above there are a number of fields were a number of 'choices' need to be stored in each field.

    e.g. Gender (M/F), Part (See lists above) and Costume (Hired or Made)

    For these fields we use the data type of 'Look up Wizard'. A look up wizard will allow you to store choices in a field so that when you are entering data, the value can be chosen from a list.

    What are the advantages of this?

The Look up Wizard

In task 2 you will be shown how to set up a 'Look up wizard'. Below is a screen shot of how they work once they have been set up. In this example a look up has been set up for the 'Gender' field, given the value 'M or F'.

Look up example

The ID field

It is important that each record in the database is unique so that data can be searched for. Which field can be used from the fields given above for a 'unique' field. Surname? Forename? Year?

None are suitable as many people have the same surname and forename, and sometimes people who have the same surname and forename live at the same address. Therefore we need to create a unique identifier for every record. One way of doing this is by including an 'ID' field.

'ID' fields can be given the data type 'Autonumber'. This will means that every record in the database is given a unique number when created. This helps prevent duplication of data. An example of this can be seen below.

Example of ID field

Homework

For homework complete the 'Pupils Data Types Exercise...' sheet by adding the fields shown above and choosing the correct data type.

The 'ID' field has already been completed for you.

When completing the homework sheet you also need to give consideration to the fields 'Field size', 'Required?', 'Description'.

Field Size

Databases can contain a large amount of data. One way of reducing the amount of data is by making sure the 'Field size' is just big enough to hold the data. Otherwise the field size is automatically set to '50'. This means it can hold a maximum of 50 characters - either text or numbers.

Think about the field size when you plan out your database table. What is the minimum size required for the:

  • Surname field
  • Forename field
  • Address Field
  • Postcode field
  • Telephone number field

Required?

The required field serves to make sure that important data must be entered into the database. If you make a field 'required' then data has to be filled in or the software will not allow you to go any further.

Which fields must be required for the cast table?

Description

The description field is needed when you decide to use abbreviations for your field names. For example you could shorten the Surname field name to just 'SN'. You would then include a 'Description' to explain what the abbreviation means.

By using abbreviations you are also making sure that your database does not get too large!

Note: You cannot begin Task 2 if you have not planned out your database first!



Click Link to view  Data Types sheet.doc
Click Link to view  Pupils Data Types Exercise for homework.doc
Click Link to view  Task 4 Part 2_Mail Merge.pdf

 


Return to Y10 HomeLittle Theatre Company Task
Evening of Story Telling task