CS 4432 Database Systems II Lecture 1: Introduction - PowerPoint PPT Presentation

About This Presentation
Title:

CS 4432 Database Systems II Lecture 1: Introduction

Description:

Beginning database knowledge as gained in say CS3431 ... A Brief Pre-amble. CS4432. Notes 1. 12. Isn't Implementing a Database System Simple? Relations ... – PowerPoint PPT presentation

Number of Views:119
Avg rating:3.0/5.0
Slides: 28
Provided by: siro7
Learn more at: http://web.cs.wpi.edu
Category:

less

Transcript and Presenter's Notes

Title: CS 4432 Database Systems II Lecture 1: Introduction


1
CS 4432Database Systems II Lecture 1
Introduction
2
Recommended Background
  • Beginning database knowledge as gained in say
    CS3431
  • Some knowledge of software engineering (Java),
    such as CS3733.

3
Staff
  • INSTRUCTOR Professor Murali Mani
  • Office Hours
  • Mondays 1130 1230. Thursdays 1030 - 1130
    am
  • TEACHING ASSISTANTS
  • Di Wang
  • wangdi_at_cs.wpi.edu
  • Office hrs from webpage

See course webpage (https//my.wpi.edu) for
office location hours.
4
Protocol for Communication
  • Come to Office Hours!!
  • We have many office hours spread throughout the
    week. This is your resource! Use it !
  • Post to discussion board mywpi
  • E-Mail cs4432-staff _at_ cs.wpi.edu
  • Expect at least a 24 hour response time

5
Details
  • LECTURES Monday, Tuesday, Thursday, Friday 900
    - 950 pm AK233
  • TEXTBOOK
  • Garcia-Molina, Ullman, Widom "DATABASE SYSTEM
    IMPLEMENTATION, or
  • DATABASE SYSTEMS, THE COMPLETE BOOK
  • WEB SITE
  • http//my.wpi.edu and
  • http//www.cs.wpi.edu/cs4432/d08
  • Please check website daily for last minute
    announcements.

6
Logistics
  • ASSIGNMENTS
  • 3-5 Written Homework Assignments.
  • PROJECTS
  • 2 3 Group Projects
  • EXAMS
  • 2 Exams
  • GRADING
  • Midterm 25
  • Final Exam 25
  • Homework Assignments 20
  • Projects 30
  • Class participation /-

7
More Details
  • Late Policy
  • No late anything will be accepted !
  • Note
  • For special circumstance and under instructor
    discretion, one late submission of up to 48 hours
    may be granted.
  • Cheating
  • No cheating of any kind !
  • If cheating identified, you will receive an F,
    and you will be reported to the proper WPI
    honesty board.

8
Planning Miscellaneous
  • BS/MS Credit
  • Database Projects MQP or ISP
  • DB Undergraduate Research Position
  • Summer Research (WPI/CRA/etc).

9
Database Material at WPI
CS 3431
B, C terms
you are here
CS 4432
D term (alternate)
CS 542
CS 561
CS525
MQP/ISP
DSRG
Grad. DB
Advanced DB
Selected
Selected DB Project
DB Research at WPI
Spring
Varies
Any time
year round
DONT TAKE!
10
Interested in Research ?Curious about Graduate
School?Take opportunity to visit WPI GRAD 2006
!Mar 19, Wed,Campus Center !
11
A Brief Pre-amble
12
Isnt Implementing a Database System Simple?
13
Naïve Implementation
  • Relations stored in files (ASCII)
  • e.g., relation Students is in /usr/db/Students

Students
Depts
Smith 123 CS Jones 522 EE
CS Fuller Labs EE Atwater Kent PH Olin
Hall
. .
. .
14
Naïve Implementation Details
  • Directory file (ASCII) in /usr/db/schema

StudentsnameSTRidINTdeptSTR DeptsnameSTRo
fficeSTR
.
.
.
15
Sample Query
select Students.name,Depts.office from
Students,Depts where Students.dept Depts.name
and Students.id gt 300
Smith 123 CS CS Fuller Labs Smith 123
CS EE Atwater Kent Smith 123 CS PH
Olin Hall Jones 522 EE CS Fuller
Labs Jones 522 EE EE Atwater Kent Jones
522 EE PH Olin Hall
16
Execution Process
  • To execute select from R where condition
  • (1) Read dictionary to get R attributes
  • (2) Read R file, for each line
  • (a) Check condition
  • (b) If OK, display

17
Yet Another Execution
  • To execute select A,B from R,S where condition
  • (1) Read dictionary to get Students,Depts
    attributes
  • (2) Read Students file, for each line
  • (a) Read Depts file, for each line
  • (i) Create join tuple
  • (ii) Check condition
  • (iii) Display if OK

18
Whats wrong ? Layout ?
  • Tuple layout on disk
  • Example
  • - Change string from Cat to Cats and
    we have to rewrite file
  • - ASCII storage is expensive
  • - Deletions are expensive

19
Whats wrong ? Search ?
  • Search expensive no indexes
  • e.g., - Cannot find tuple with given key quickly
  • - Always have to read full relation

20
Whats wrong ?
  • Brute force query processing
  • e.g., select
  • from R,S
  • where R.A S.A and S.B gt 1000
  • - Do select first?
  • - More efficient join?

21
Whats wrong ?
  • No buffer manager
  • e.g., Need caching

22
Whats missing?
  • No concurrency control

23
Whats wrong ?
  • No reliability
  • e.g., - Can lose data
  • - Can leave operations half done

24
Whats wrong ?
  • No security
  • e.g., - File system insecure
  • - File system security is coarse

25
System Structure
Query Parser
User
Strategy Selector
User Transaction
Transaction Manager
Buffer Manager
Recovery Manager
Concurrency Control
File Manager
Log
Lock Table
M.M. Buffer
Statistical Data
Indexes
User Data
System Data
26
Course Overview
  • File System Structure
  • Records in blocks, dictionary, buffer
    management,
  • Indexing Hashing
  • B-Trees, hashing,
  • Query Processing
  • Query costs, join strategies,
  • Crash Recovery
  • Failures, stable storage,
  • Concurrency Control
  • Correctness, locks,
  • Transaction Processing
  • Logs, deadlocks,
  • Additional Topics
  • If time permits

27
Next time
  • The lowest layer Hardware
  • Read chapter 11
Write a Comment
User Comments (0)
About PowerShow.com