What is a database?

Databases - Lesson 1

Objectives

  • To understand and explain what a database is
  • To identify records and fields of a database. 
  • To identify advantages and disadvantages of using databases.

 

Introduction

 

Before the lesson make a copy of this Google Spreadsheet ‘My Favourite’. Open the doc, go to ‘File’ and choose ‘Make a copy’ and rename the document. On your copy add your students’ names to the ‘name column’. Finally, share the new copy with your class (as editors) just before the lesson. (Collecting together your class’ email addresses before the lesson so you can copy and paste them, or make a group in your contacts makes sharing much easier.)

 

If your school uses Microsoft 365 for Education, open the same ‘My Favourite’ file and go to 'File' and choose 'Download as' > 'Microsoft Excel'. Then upload the Excel spreadsheet to your One Drive or Sharepoint account and share it with your class.

 

What is a database?

Begin by asking What is a database? Ask the students to discuss with a partner first, and try to give real life examples or an educated guess if they haven't heard of the term before.

 

“A database is a system that makes it easy to search, select and store information. Databases are used in many different places.”

(BBC Bitesize: https://www.bbc.co.uk/bitesize/topics/zf2f9j6/articles/z8yk87h#z996tfr)

 

Ask - So what is data? and what is the difference between data and information?

 

Data refers to factual information, especially that which is used for analysis and based on reasoning or calculation. Data itself has no meaning, but becomes information when it is interpreted. Information is a collection of facts or data that is communicated. 

An address book is a paper-based database, would this be useful? How is it organised? Are there difficulties in using a paper-based system? - Slower to search and organise, perhaps more easily damaged/lost etc, limited space sometimes.

Where do most people keep their telephone numbers and address now? What advantages do electronic systems have? - Faster to search, often accessible to many people at once, from more than one location. 

Go to this BBC Bitesize page and look at the different parts of a database (part 3). Click on each label for an explanation.

 

 

Search - You can search your database for keywords. If you search for 'toy shelf' all of the records which have a field containing the phrase 'toy shelf' will be shown. This set of results is called a record set.

Titles - Each column in your database will have a title. All of the fields underneath this title are storing information about location.

Record - Each row (or ‘card’) in your database is a record. This record is for a monster toy called Tom. Tom is currently on the toy shelf and is green.

Field - Fields are the individual bits of information in your database. For example this field is storing the colour of one of the toys.

 

Where might we use databases? 

Ask the students to talk to their partner again and choose one of the locations on the image below. Why might they use a database in that place? What sort of data might be stored in their database? Have a look at the examples on the BBC Bitesize page.

 

(examples from BBC Bitesize)

 

Supermarket

A supermarket will store the details of all its products in a database. This means it knows when items are running low and when to order more.

The price of each item will be stored in the database. When an item is scanned at the checkout, the program running on the till will check the database and add the cost of the item to your bill.

 

Library

When you want to borrow a book from a library you can browse their 'catalogue'.

This is a type of database that stores information about every single item in the library. It might store information about a book's title, author and if it is available.

Many libraries share their catalogues with other libraries. So, even if the book you want is not available, you can order it from another library.

 

Hospital 

Doctors used to keep all the details about patients on record cards in a filing cabinet. Now they are all stored in a database.

This allows a doctor to quickly look up a patient's medical history. They can check what illnesses they've had in the past or medicines they have been prescribed.

All the files on the database are secured with a password so that only doctors and nurses can access them.

 

School

Lots of people around your school, like your teacher and head teacher, will use databases every day. They might have a database to keep track of each pupil's personal details, like their name, year group, home address and parent’s phone numbers.

Teachers might also keep a database tracking how well you and your classmates are doing in class. This could be a record of test results and grades so they can see your progress throughout the term.

 

Collaborative web tools

Explain we will be looking at a few electronic tools that will let us collect information for a database quickly and then let us build a shared database. 

If the students are not already familiar with Google Drive and Docs introduce it all to them. (Use One Drive and Office 365 documents if your school is a Microsoft user). 

 

Google Drive

Show the children how to open their Google Drive from their Gmail Inbox.

 

 

One Drive 

If using Microsoft 365 - Show the children how to open their One Drive from their Office 365 dashboard.

 

 

What is your Google/One Drive and how does it work?

Your Google/One Drive is an online storage area for files. You can:

  • Upload any file type for storage -
  • Some files stored in your Drive allow online editing and collaboration with other people working on them at the same time. 
  • Share uploaded file with others - This allows them to view or work on documents with you so you don't need to email them copies. 

It is also a home and default save area for their Google/Microsoft documents - a free office suite of applications which:

  • are collaborative - lots of people can work on them at once, from anywhere.
  • are web based so can be accessed anywhere (with a web connection)
  • auto saves - there’s no save button, never lose work again when you forget to save!

 

Create or Upload in Google Drive

Briefly discuss the types of docs available but don’t look at them all yet. 

Create a ‘Google Doc’ and show how to name it. Show the basic editing tools and that it’s just a word processor.

 

Create or Upload in Microsoft One Drive

Briefly discuss the types of docs available but don’t look at them all yet. 

Create a ‘Word Document’ and show how to name it. Show the basic editing tools and that it’s just a word processor.

 

Sharing documents

Then show how to share the document with someone else, the search facility and the choices you have when you share the doc; whether they own, can or can’t edit etc, making it open to anyone with the link (to view or edit).

 

Google Docs:

Office 365:

 

Choose someone sensible to help you demonstrate and make sure they are logged in to their Google or Microsoft account and have their email open already.

Share your document with them and ask them to open it (point out they will get an email but that it will also be in the ‘Shared with me’ section of their Google Drive ('Shared' in One Drive.)

Begin writing a sentence and then ask your helper to click after your full stop and write the next line, continue to take it in turn once more each. Show how you can edit each other's’ work so that there needs to be trust, respect and a sensible attitude to working together like this.

Close the document but show how it is now in your Google/One Drive so you could come back to work on it later, how could that be useful for you? (Home/school working)

All types of Google/Office 365 documents work in a similar way and allow multiple people to edit them at the same time online.

 

Main tasks

Open your copy version of ‘My favourite’ and explain that this is a different kind of document (a spreadsheet) that splits the page into cells, has anyone used a spreadsheet before?

This file works in the same way as the Doc you just demonstrated, in that more than one person can work on it together. Share it with everyone in the class and ask them to add their favourite thing for each category to the cells on their row. Emphasise again how important it is that they stick to their own row and do not edit anyone else’s work. They wouldn’t dream of changing someone else’s work in their book, so be respectful and don’t do it here either.

This highlights perfectly how effective it is to have everyone working on one doc at the same time.

When they are finished ask - How else could we have collected that information from everyone? Discuss more traditional methods such as going round the class and asking everyone one by one, making paper based notes, and how time consuming they might be in comparison.  

Demonstrate how the data in the table can be sorted A - Z. Click on the Food column by clicking on its letter column header (B).

 

 

Then go to Data > Sort sheet by column B, A - Z

 

 

Sort Ascending in Excel:

 

This will group answers together if people gave any same answers but might also highlight a potential problem with the data collected... spelling! As the sheet allows free text entry spelling errors will record the same answer as different things, which if not corrected could cause data analysis errors later.

This can be highlighted by turning the data into a graph. Highlight column B again and go to Insert > Chart.

 

 

This should automatically turn it into a (recommended) bar-chart. It usually displays better as a horizontal bar chart (as the labels show better). You can tweak its layout and design in the customisation tab if you want to. But it can be seen in this example that pepperoni pizza and pizza are shown as separate entries, which should really be grouped as one.

Scroll down the spreadsheet view again, ask -

  • Have we any spelling or text errors in our food column?
  • What is the most popular food in our class?
  • How many people voted for that?
  • Were any foods only voted for by one person?
  • Which ones?

 

Plenary

Ask the students to explain to a partner what a database is and an example of where one might be used. Check their understanding after this.

Explain that completing ‘My Favourite’ was fairly easy as all the answers were about us, so we just had to think of our own answer. In the next lesson we will be researching a different topic in order to create another shared class database.

Next Lesson >