CS145 - Introduction to Databases
Spring 2000, Prof. Widom
Midterm Exam: Logistics and Review
Information
- The midterm exam will be held on Wednesday May 3 from 11:00 AM
until 12:15 PM in the Gates Computer Science Building Room B01 (the
Hewlett-Packard Auditorium) on the Stanford campus. All students,
including SITN students, are expected to attend the exam on-campus.
There will be no early or makeup exams.
- The exam will be closed book. However, each student may bring up
to three pages of prepared notes. That's six total sides of writing
on 8-1/2"x11" paper.
- Sample exams from Prof. Widom's Spring '98 offering of CS145 are
linked to the course home page.
- A sample solution for Written Assignment #3 will be linked to the
course home page no later than midnight on Monday May 1.
- SITN Students: Please be sure to bring a routing slip with you
to the exam. If you do not bring a routing slip, we will not be able
to send your graded exam back by courier.
Review Session
A question-and-answer review session will be conducted by one of the
TA's on Tuesday May 2 from 7:00-8:30 PM in the usual CS145 classroom:
the Gates Computer Science Building Room B01 (the Hewlett-Packard
Auditorium). Please bring questions or specific problems for the TA.
The review session will not be televised.
Material Covered
The exam will cover:
- All lectures through Wednesday April 26
- Textbook readings: Chapters 1, 2.2-2.3, 2.4.3-2.4.4, 2.5
except 2.5.2, 2.6, 3.1, 3.3, 3.4.2, 3.4.4, 3.5-3.8, 4.1,
4.6.1-4.6.6, 5.1-5.7, 5.9, 7.1-7.4
- Written Assignments #1-3
- Project Parts 1-4
Since the material on transactions, authorization, and programming
with SQL (covered in class and in the readings) has not yet been
exercised in an assignment, any questions regarding this material on
the exam will be straightforward.
What follows is an outline of the material we've covered so far.
All of this material is fair game for the midterm exam.
- Basic motivation and database terminology
- Entity-relationship model and E/R diagrams
- Entity sets, relationship sets, attributes, keys, roles
- Multiplicity of relationship sets (one-to-one, one-to-many, etc.)
- Weak entity sets
- Subclasses ("isa" relationships)
- Relational model
- Relations (tables), attributes (columns), tuples (rows)
- Schema versus instance
- Keys, null values
- Translating E/R designs to relations
- Relational database design
- Functional dependencies (FD's): motivation, definitions, rules
- Closure of attribute set with respect to FD's
- Design flaws: redundancy, update & deletion anomalies
- Boyce-Codd Normal Form (BCNF): motivation, definition, decomposition algorithm
- Multivalued dependencies (MVDs): motivation, definitions, rules
- Fourth Normal Form (4NF): motivation, definition, decomposition algorithm
- Relational algebra
- Basic operators: select, project, Cartesian product, union, difference, rename
- Abbreviations: natural join, theta join, intersection
- Bag relational algebra
- SQL
- Data definition: create table, drop table
- Data manipulation: select command
- Subqueries, aggregates, duplicates, null values, join operations
- Data modification: insert, delete, update
- Indexes
- Properties and uses of indexes
- Creating indexes in SQL
- Transactions, Authorization, Programming with SQL: cursory coverage only