Create a Database
Create a Database
Grade 11
Topic: Database Management
Specific Objectives
• Create a database
4. Click create
Now that you have created the Bookshop database, it is time to learn
• Field name
• Field length
• Field description
• Field properties
Challenge yourself!!
For EACH table components given on the previous slide give a description and an
example.
1 Select the Create tab, locate the Table group, then click
the Table Design command. For now the table is called Table 1.
2
Click in the first Field Name box and type ‘CID’, then press Enter. In the data type column,
choose the Text type, press Enter, then Type the Description as ‘Customer ID Number’.
Field Size: 4
to your table
listed below and identify when they are most suitable to be used.
• Candidate key
• Composite key
• Foreign Key
key is not chosen Microsoft Excel will ask you if you would like to create one
4 For this exercise. Make the CID field the primary key, meaning that every item has 4
dialogue box
Put your brain to work!!
In the same Bookshop database create the following tables
Make PR-ID the primary key and save the table as Product.
Field Name Data Type Description
CID Text Customer ID
PR-ID Text Product ID from Inventory
Qty Number Quantity ordered
Discount Yes/No 10% discount offered on
Product
• Information can be accessed and coordinated in all the fields of the connected tables
• Save you from having to enter the same information in several tables
• Allows you to create forms, queries and reports from the related tables in the database file
Joining Multiple Tables
Tables should be join, so that
• Information can be accessed and coordinated in all the fields of the connected tables
• Save you from having to enter the same information in several tables
• Allows you to create forms, queries and reports from the related tables in the database file
Challenge yourself!!
The linking of two tables can occur in one of two ways:
• one-to-one
• one-to-many
tables.
You can start entering data once you have completed the table design.
3 To switch views between the Datasheet and the Design view, simply
4 Click the Datasheet view and enter the data shown below into the customer
provided below
PR-ID Description Cost
P3122 Pocket Diary $8.95
P3429 Jumbo Clips $4.15
P3430 Small Clips $2.75
Product Table
Customer ID Product-ID QTY Cost
1128 P3430 10
1128 P3902 50
Order Table
Manipulate data in a database (Forms)