Skip to content
IGCSE·Tuition
ICT · Lesson

Compare displayed results with the source dataset

A tidy report feels finished, but only a comparison with the source shows whether it is correct.

On this page
  1. What is a reliable checking routine?
  2. Worked example
  3. The mistake to watch for
  4. Check yourself
  5. Where this leads next

Comparing displayed results with the source dataset means checking a query or report against the original table using counts, names and totals. It appears in practical tasks that ask you to prove or evidence that your results are correct.

This lesson closes database queries and reports and uses ideas from all four lessons before it. It also supports the evidence skills in the ICT practical task and evidence checker.

What is a reliable checking routine?

  1. Write down what the task expects before running anything: which records and roughly how many.
  2. Count the matching records directly in the source table.
  3. Run the query and compare the count.
  4. Compare names or IDs to find any extra or missing record.
  5. Check one total by adding the source values yourself.
  6. Spot-check one calculated value by hand.

Worked example

Using the invented Harbour Hill Clubs table from the module page.

Task: report all members with Fee total, sorted by name.

Step 1, expected: all 10 records. Fee total from the source: 4 at RM30 = 120, 3 at RM45 = 135, 3 at RM60 = 180, so 435.

Step 2, the report shows: 9 rows and a fee total of 375.

Step 3, difference: 10 - 9 = 1 record missing, and 435 - 375 = 60.

Step 4, find it: a RM60 member is missing. Robotics members Evan, Farah and Jia each pay 60, and scanning the names shows Jia is not in the report.

Step 5, cause: a leftover criterion Sessions > 5 was still switched on. Jia attended exactly 5 sessions, so she was filtered out.

Step 6, fix: remove the criterion and re-run. The report shows 10 rows and 435.

The total pointed straight to a RM60 record, which narrowed the search a lot.

The mistake to watch for

Trusting that a result is right because it looks tidy:

The report shows 9 rows, neatly sorted, so the student submits it.

No error message appeared, but one record was filtered out, and the total is RM60 short.

The correction is to run the routine above every time, even when time is short. Counting 10 records in the source takes seconds.

Check yourself

1. A query for Fee >= 45 should return how many records, and what is their fee total?

Show answer

Fee 45: Bella, Chen, Gopal. Fee 60: Evan, Farah, Jia. 6 records, total 3 * 45 + 3 * 60 = 135 + 180 = 315.

2. A query for Sessions > 10 shows five records. Is that right?

Show answer

No. More than 10 means 11 or 12: Bella (12), Dewi (11), Farah (12), Imran (12). That is 4 records. Hui has exactly 10 and is excluded. A five-record result probably used >= instead of >.

3. The average number of sessions across all members is shown as 9.2. Check it.

Show answer

Total sessions: 8 + 12 + 9 + 11 + 7 + 12 + 6 + 10 + 12 + 5 = 92. Then 92 / 10 = 9.2. The displayed value is correct.

Where this leads next

Put all five lessons together in the database queries and reports practice set. The read-only SQL practice lab gives you a bundled fictional database to compare against, and the mistake log and retest queue helps you track the slips you repeat.

A teacher can watch you check a report and point out the step you skip, in online one-to-one ICT tuition.

Questions people ask

How can I check a query without running it again?

Work out the expected records by reading the source table by hand, count them, and compare the count and the names with the result. If the count differs, find the missing or extra record. This works whatever software you use.

What should I compare apart from the record count?

Compare the names or IDs, one or two spot values, and any total. A total checks many values at once. If the count and the total both match the hand calculation, the result is very likely right.

What if the report and the source disagree?

Do not assume either is right. Re-check your hand count first, then look for a leftover filter, a wrong comparison symbol, a hidden field or a number format that rounds the display. Fix one thing at a time and re-run.

Updated:

Your next step

If you tend to submit a query as soon as it runs, a one-to-one teacher can practise a short checking routine with you until it takes under a minute.

Paid one-hour trial at your assigned teacher’s confirmed rate, starting from RM80.

Tuition is arranged with a parent or guardian. Send them this page on WhatsApp and they can enquire for you.

Parents: enquire here

  • 9,000+ students helped through our service
  • 9+ years helping IGCSE students