CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.
-
Upload
joy-lester -
Category
Documents
-
view
226 -
download
0
Transcript of CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.
![Page 1: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/1.jpg)
1
CSCI3170 Introduction to Database Systems
Tutorial 2 – Project Specification
![Page 2: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/2.jpg)
2
Outline Introduction Data Specification Assumption System Function
![Page 3: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/3.jpg)
3
Introduction Library Inquiry System
You need to implement a library inquiry system Language: JAVA JDK 6.0 (with JDBC) Platform: Windows 7 Enterprise (32 bits) Database: Oracle Database 11g Enterprise
Edition (r11.1.0.6.0)
Database accounts will be given to you after group registration phase
Tutorials will be given on Oracle, JAVA and JDBC
![Page 4: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/4.jpg)
4
Grouping Each Group should have 3 students Form your groups online at course webpage
Deadline: 30, Sept, 2011 Students who do not form groups after the deadline
will be assigned into groups by tutors If you want to have group of 2 students
Please send an email to the tutor (pywong) We will try our best to arrange it
One more student may be assigned to the groups if there are single students
Groups will be finalized by 7 Oct 2011 Please check the course webpage and email (if any)
for details
![Page 5: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/5.jpg)
5
Project Milestones Phase 1 (15%)
E-R diagram design (hard-copy) A suggested ER diagram will be released after the
deadline Phase 2 (20%)
Relational schema design and Proof of 3rd Normal Form(hard-copy)
A suggested schema will be released after the deadline
Phase 3 (65%) Implementation of the system (soft copy) Final Report (hard-copy) Demo
![Page 6: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/6.jpg)
6
Timeline
Phase Deadline
Group registration 30 Sept 2011
Phase 1 14 Oct 2011
Phase 2 28 Oct 2011
Phase 3 25 Nov 2011
DEMO 29 Nov 2011 (Tentative)
![Page 7: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/7.jpg)
7
Data Specification The data are in four categories
User category Library user Book information Checked-out book copy
They are used for explanation purpose only Not meant to be the tables in the final schema
![Page 8: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/8.jpg)
8
Data Specification The user category determines the permission
of users Category ID
A unique identifier for a category Max Books
The maximum number of books that a user can borrow Loan Period
The number of days that a user can borrow a book
![Page 9: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/9.jpg)
9
Data Specification The following information of a user are stored
User ID A unique identifier of a user (like student id in CUHK
library system) Name
The name of a user Address
The contact address of a user Category ID
The user category that a user belongs to
![Page 10: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/10.jpg)
10
Data Specification The following information of a book are stored
Call number A unique identifier for each book
Number of copies The number of identical copies of a book Each copies of the same book are distinguished by copy
number Title
The title of a book Author(s)
Author name(s) of a book Date of publication
The date that a book is published
![Page 11: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/11.jpg)
11
Data Specification The checked-out book stored which book
copies are checked-out Call number
The number of the checked-out book copy Copy number
The copy number of the checked-out book copy User ID
The user which borrow the book Check-out date
The date that the book is checked-out
![Page 12: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/12.jpg)
12
Assumptions and Regulations System
All numerical values are less the 232 The system is case sensitive
User Category The category ID is unique
![Page 13: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/13.jpg)
13
Assumptions and Regulations Library User
The user ID is unique The user name is not unique The user address is not unique A user can belongs to only one category
![Page 14: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/14.jpg)
14
Assumptions and Regulations Book information
A book copy is uniquely identified by the call number and copy number
The copy number begins with one For one copy, the copy number is 1 For N copies, the copy numbers are 1,2,…, N
An author is uniquely identified by his/her name An author writes a book rather an author writes an
book copy Each book have at least one author Each author record in the database must be an
author of at least one book A book can have more than one author
![Page 15: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/15.jpg)
15
Assumptions and Regulations Checked-out book copy
A library user can never checked-out any book copies
A book copy can never been checked-out
Sample Datasets A sample dataset will be provided to you after
phase 2 for testing your implementation
![Page 16: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/16.jpg)
16
System Functions You have to implement three interfaces
Administration interface Enquiring interface Evaluation interface
You can implement user interface in command line mode You are welcome to implement GUI But no extra marks for GUI
![Page 17: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/17.jpg)
17
System Functions Administration Interface
Create table schemas in the database Delete table schemas in the database Load data into the database
Your system should read data files and insert them into the appropriate tables
Please make sure that it can read the sample data provided
A sample data reader will also be posted on the course webpage
![Page 18: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/18.jpg)
18
System Functions Enquiring interface
Search for books (only one method per query) By call number (exact matching) By title (partial matching) By author (partial matching)
Output should include Call number Title Author(s) Number of available copies List of checked-out copies
![Page 19: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/19.jpg)
19
System Functions Enquiring interface
Show loan status (one method per query) By user ID (exact matching) By user name (exact matching)
Output should include User ID Name Address List of books checked-out by the user
![Page 20: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/20.jpg)
20
System Functions Enquiring interface
Check book overdue information The user input a date The system output all books that are overdue on or
before that date The output is in ascending order of due date
Output should include Name of borrower Call number Copy number Title Checked-out date Due date
![Page 21: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/21.jpg)
21
System Functions Enquiring interface
Show newest books The user input a number n The system output all books that are published within n
days The output is in ascending order of publication date
Output should include Call number Title Author(s) Number of available copies
![Page 22: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/22.jpg)
22
System Functions Evaluation Interface
Show all information of the database tables Show the number of users in each category
The output should be in descending order of the number of users
Show the N most productive authors The user input a number N The system output the top N authors that published the
most number of books The output should be in descending order of the
number of published books If there are authors who have the same number of
books as the Nth author, they should also be output
![Page 23: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/23.jpg)
23
Demo
![Page 24: CSCI3170 Introduction to Database Systems Tutorial 2 – Project Specification 1.](https://reader035.fdocuments.us/reader035/viewer/2022062217/56649e665503460f94b60417/html5/thumbnails/24.jpg)
24
Q&A