Easier to read with cream paper, a tint, more contrast or larger text? Choose your colours and text, once, for every page.

Preview

Keeping data good: quality checks

This is the first page of the lesson. Read it and have a go at the activities. The rest is in the full lesson.

45 minutes

The trip form that went wrong

A school trip form is typed into a computer. Look at the list.

Sam is 160 years old. Aisha has two rows. Leo lives at "LS1 1AB" on one list and "LS1 1BA" on another. The bus company sends the tickets to the wrong place.

Six checks can stop this. You will learn all six.

Key words

WordWhat it meansExample
ValidationA check that data is sensible and in the right shape.An age of 160 is refused.
VerificationA check that data was copied or typed in correctly.Type your email twice.
ReliabilityData you can depend on, from a trusted source.A school office list
ConsistencyThe same fact is the same everywhere it is kept.One address, two lists, no difference.
IntegrityData stays complete, correct and joined up. Nothing is lost or damaged.A ticket always points to a real student.
RedundancyThe same data kept more than once when it is not needed.Aisha twice in one list
RecordOne row of data about one thing, such as one student.Sam, 16, LS1 1AB
Range checkA validation rule: the value must be between two limits.Age from 11 to 19

The cells students fill in are left blank in this preview.

Validation: is it sensible?

Validation checks that data is sensible and in the right shape. The computer does it by itself, when the data goes in.

Age 160? Refused. A postcode with no space? Refused. An empty name? Refused. Validation is a gate at the door.

Quick check: validation

Have a go

Quick check: validation

3 questions
Have a go: your answers are marked here and then forgotten. Sign in if you would like your score kept, and to pick up where you left off.Sign in to keep your score

Your answers are marked here and are not kept. A college account keeps every student’s marks.

Try it: validation is not proof

Code: python
age = 17          # the student is really 16

if 11 <= age <= 19:
    print("Valid: the age is sensible.")
else:
    print("Refused.")

# Validation says yes, but the age is wrong.
# Change 17 to 160 and press Run again.

Verification: was it typed right?

Verification checks that the data was copied or typed in correctly. The age 17 passes validation, but only a second look shows it should be 16.

Common ways: type the data twice (double entry), or ask a person to read it back and check.

Four more ideas

Reliability: you can depend on the data. It comes from a trusted source and does not change by itself.

Consistency: the same fact is the same in every place. The address is not different on two lists.

Integrity: the data is complete and not damaged. Every ticket points to a real student.

Redundancy: needless copies. Aisha is on the list twice.

Quick check: the four ideas

Have a go

Quick check: the four ideas

3 questions
Have a go: your answers are marked here and then forgotten. Sign in if you would like your score kept, and to pick up where you left off.Sign in to keep your score

Your answers are marked here and are not kept. A college account keeps every student’s marks.

The lesson goes on

7 more parts of this lesson are in the full curriculum, with the tasks, the final check and the labs. A college account gives your students all of it.