Potential Midterm Topics
DBMS, Spring 2008
Johnson

It goes without saying, but you're responsible for all material covered in lecture (and not just in PPTs) and for all assigned reading. Naturally, the greatest emphasis will be on material from lecture, and the least emphasis will be on material from the assigned "skimming" (although there may be some to check that you did it). On the other hand, anything that's in the slides that was skipped wasn't covered, and doesn't count (4NF, for example). sqlzoo.net would be a very good thing to study. There are also the boat R.A/SQL examples in the text, some of whose solutions are provided on the text's website. Try to solve them without looking at the answers. Also, try, when possible, to solve queries multiple ways, i.e., with and without grouping/aggregation, with and without subqueries, etc.

The exam is intended to be challenging. It won't necessarily be the sort of exam that you need a 95% to get a good grade. (Of course, grades are curved, so this could happen...)

Although particular vendor-specific differences have come up occationally, I with not ask you, for example, whether Oracle or MySQL supports some feature or requires non-standard notation.

General skills to have

modeling a description of data in E.R.
converting E.R. models to relational models
normalizing relational models
-recoginizing keys and FDs
writing queries in SQL
understanding what SQL/RA statments mean
basic syntax for creating tables

Particular topics to know about:

weak entity sets/supporting relationships
converting relationships to weak entity sets
relationships v. relations

relaltionship multiplicity
-1-1
-many-1
-many-many

multiway relationships
entity sets playing multiple roles

the concepts of ISA relationships
-conversion details are less important

converting E/Rs with weak entity sets to relations

FDs
-keys
-inferring FDs from given FDs
-closure algorithm

"causes" of anomalies

anomalies from redundancy
-update anomalies
-delete anomalies
-insert anomalies

decompostion(A,B,C)

lossless v. lossy decomposition
-which decomps are lossless?

normal froms
-BCNF (what's the slogan?)

decomposition algorithm
-for BCNF

sets v. bags
bag-theoretic operations

all SQL keywords/clauses
-comparison operators
-LIKE
-DISTINCT
-ORDER BY
-IN
-GROUP BY
-HAVING
-ANY
-ALL
-UNION/INTERSECT/DISTINCT
-UNION ALL/INTERSECT ALL/DISTINCT ALL

implicit cross product in SQL
new-style joins v. old-style joins
assigning vars to relations/queries (why?)
h what cross product means
set operators in SQL
disambiguating

nulls in SQL
-three-valued logic

subqueries
-correlated subqueries
ways to find different pairs (with conditions)
ways to find min/max (with conditions)
existential/universal (which is easier?)
explicit crosses and joins

grouping & aggregation
-aggregation operators
-difference between WHERE and HAVING

basic syntax for modifications

default field values

purpose of views
foreign keys/referential integrity

"dangling tuples"

keys in the relational model, keys in SQL

indices -why, when indices are/should be used
-how BSTs work
-why/by how much binary search is faster than linear search
-exponentiation and logs (base 2)