0% found this document useful (0 votes)
55 views14 pages

Tutorial B (Build An Access DB) READ FOR GUIDELINES HOW TO DO TUTORIAL A

The document provides instructions for implementing a student exam grade database in Microsoft Access. It includes an entity relationship diagram showing tables for students, parents, exams, and exam attempts. It describes the key fields for each table and relationships between tables. It then provides step-by-step instructions for creating the database in Access and defining the tables and relationships. It also demonstrates how to write and run SQL queries in Access.

Uploaded by

Trang Nguyễn
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
55 views14 pages

Tutorial B (Build An Access DB) READ FOR GUIDELINES HOW TO DO TUTORIAL A

The document provides instructions for implementing a student exam grade database in Microsoft Access. It includes an entity relationship diagram showing tables for students, parents, exams, and exam attempts. It describes the key fields for each table and relationships between tables. It then provides step-by-step instructions for creating the database in Access and defining the tables and relationships. It also demonstrates how to write and run SQL queries in Access.

Uploaded by

Trang Nguyễn
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 14

UNIVERSITY of GREENWICH

Structure Physical design.


SQL basics Tutorial.

Student System example in Access

E. I. Teodorescu 1
Dr E. I. Popa
UNIVERSITY of

Case study
TO DO: implement in Access a simple database for a
students’ exam system which will hold the grades
for students’ attempts for particular exams

A simple Student System ERD (This is an individual task)


This is a short description:
When creating a student we need to store information such as ID for unique
identification, the name, date of birth, gender, a username, password
Many exams is taken by many students. To clarify this, a student can have
many attempts for an exam and an exam can have many attempts by students.
The system should also store information about one parent of each student. A
parent can have many students and the system should store a username and
password for them so they can access the system and view their kids grades.

E. I.DrTeodorescu 22
E. I. Popa
UNIVERSITY of

Student System ERD – possible answer

Notice the primary key

E. I.DrTeodorescu
E. I. Popa 33
UNIVERSITY of

How to Create a simple DB in Access


Open Microsoft Access
Create a simple Database, name it appropriately and
save it in a folder on your G drive.
Once created you are going to be able to add tables
notice that one table , Table 1 is already created –
please rename it appropriately by right clicking on it.
To create new tables go to the CREATE tab at the top
The following slides will show the tables and
columns that you should create

E. I.DrTeodorescu
E. I. Popa 44
UNIVERSITY of

How to create tables and relations in Access

E. I.DrTeodorescu
E. I. Popa 55
UNIVERSITY of

Parent table
Has a primary
key ParentId
which we use
in the
Student table

E. I.DrTeodorescu
E. I. Popa 6
6
UNIVERSITY of

Student table
Has a foreign key
fkParentId which is the
primary key form the
Parent table- so we
know who is the parent
of a particular student
Has a primary key
which we use in the
Attempt table

E. I.DrTeodorescu
E. I. Popa 7
7
UNIVERSITY of

Exam table
Has a primary
key which we
use in the
Attempt table

E. I.DrTeodorescu
E. I. Popa 8
8
UNIVERSITY of

Attempt table
Has a foreign key
fkExamId which is the
primary key form the
Exam table
Has a foreign key
fkStudentId which is the
primary key form the
Student table
Has a primary key
which we use in the
Attempt table

E. I.DrTeodorescu
E. I. Popa 9
9
UNIVERSITY of

Running an SQL Statement


Go to Create/ then Query design

E. I.DrTeodorescu
E. I. Popa 10
10
UNIVERSITY of

Click on SQL

E. I.DrTeodorescu
E. I. Popa 11
11
UNIVERSITY of

You should get here:


Make sure that no tables
are open

Copy and paste your SQL here

E. I.DrTeodorescu
E. I. Popa 12
12
UNIVERSITY of

Run your query

E. I.DrTeodorescu
E. I. Popa 13
13
UNIVERSITY of

How to write an SQL query in Access and


run it

E. I.DrTeodorescu
E. I. Popa 14
14

You might also like