| Term | Definition |
| Schema | logical structure of the Database |
| Instance | The actual content of a database at a certain point in time |
| Physical data independence | Being able to change the physical schema without changing the logical schema |
| logical data independence | being able to change the conceptual schema without changing the application (provided by views) |
| relational model | uses a N-ary relation between attribute sets to model entity set |
| relation instance | a table with a column for each attribute which is atomic; each row represents an entity |
| relation schema | relation name followed by a parenthesized list of attribute names with associated domains followed by constraints |
| database schema | collection of relation schemas |
| type constraint | value in column must be of corresponding data type |
| data atomicity | single value in each column |
| key constraint | any relation or table has at most one row for some combination of values of key attributes |
| foreign key | an attribute of a relation which serves as a primary key of another relation |
| candidate key | a minimal set of attributes which is a key |
| superkey | any key including a set of all attributes of a relation |
| functional dependency | a set of attributes x which uniquely determines a set of Y attributes |
| determinant | left side of a functional dependency |
| anomaly | an error or inconsistency due to redundant data resulting from insertion, update or deletion |
| binary relation | a relation between two entity sets |
| cardinality constraint | a bound on the number of times an instance of an entity can be related to an instance of another entity |
| composite key | a key consisting of more than one attribute |
| relational database | a database consisting of relations (tables) |
| partial dependency | a functional dependency in which non-key attributes are functionally dependent on part but not all of the primary key attributes |
| transitive dependency | an attribute that does not depend on the key of the table |
| 3rd Normal form | no transitive dependencies |
| Boyce Codd Normal Form | a relation in which every determinant is a candidate key |
| foreign key constraint | there is a tuple or row of the primary key table with same value as value of foreign key |
| atomicity | either all actions in a transaction occur, or none |
| consistency | making sure that if a DBMS starts in a consistent state, that it ends up in a consistent state. |
| Isolation | One transaction does not affect other transactions |
| Durability | If a transactions commits then that effect is persistent |
| steal | When the system writes a page to disk if it needs it even if the transaction that changed it is still active |
| no-steal | keep page in memory if active transaction is updating it |
| force | when a transaction commits, write all pages modified by it |
| no-force | only write pages when their buffers are needed |
| analysis | 1st Aries phase: Start from some point in log and scan forward to identify all active transactions and all dirty pages |
| redo | 2nd ARIES phase: start from a point and repeat all actions up to crash point |
| undo | 3rd ARIES phase, undo the actions that did not commit. Work backwards from log |
| Write-ahead logging | write any db changes to the log in stable storage before updating the DB |
| logging changes during undo | Action that ensures that actions are not repeated during repeated faliures |
| log | A file of action records stored in stable storage |
| Log Sequence Number | Each log record has its own unique _______ |
| transaction table | table containing entries for active transactions. Elements include tranID, status, lastLSN |
| dirty page table | table containing entries for all the dirty pages in the buffer pool contains recLSN |
| write-ahead logging | A strategy for writing the log pages to stable storage. Forces the writing of log records before the data page is written. Writes all log records for a transaction before commit |
| checkpoint | point in a log where the DBMS should start the recovery from |
| transaction | series of reads and writes that are expected to be executed as a unit |
| active | transaction state where it is making progress or waiting for resources |
| failed | transaction state where execution cannot continue |
| aborted | transaction state after rolling the DB back to before the transaction occurred |
| committed | transaction state after a commit command |
| schedule | a time-ordered sequence of actions for one or more transactions |
| concurrent schedule | schedule where the actions of two or more transactions are interleaved |
| serial schedule | schedule that does not interleave the transactions of different transactions |
| equivalent schedule | a schedule what when executed produces the same effect as another. |
| serializable schedule | a schedule that is equivalent to some serial schedule |
| conflict | this occurs when two actions are both on the same data and one is a write |
| recoverable | a schedule that commits a transaction only after all the transactions that modify data read by that transaction have committed |
| conflict serializable | a schedule that is conflict equivalent to a serial schedule |
| conflict equivalent | a schedule that has all of its pairs of conflicting transactions ordered in the same way as another transaction |
| view equivalent | a schedule that always reads the same values as another schedule and that has the same transactions writing the final values as the other schedule |
| view serializable | a schedule that is view equivalent to a serial schedule |
| lock | structure that restricts access to database objects |
| shared lock | a lock that can be shared by many transactions |
| exclusive lock | a lock that can only be held by one transaction at a time |
| locking protocol | rules that define how locks should be used |
| strict 2PL | each transaction must obtain an S lock before reading and an X lock before writing. All locks are released on a commit or abort |
| 2PL | each transaction must obtain an S lock before reading and an X lock before writing. Locks can be released at any time, but they cannot request additional locks after releasing one |
| lock table | a hash table containing one entry for each data object that lists the number of transactions holding each lock |
| transaction table | contains lists of locks for each transaction |
| lock upgrade | converting a S lock to a X lock |
| lock downgrade | converting a X lock to an S lock (can only happen if it does not change the object) |
| blocked | a transaction that is waiting for a lock |
| deadlock | when two or more transactions are blocked, waiting for each other |
| waits-for graph | graph used to detect deadlocks by discovering cycles |
| wait-die | deadlock policy: If T1 wants something T2 has, T1 waits if it has a higher priority than T2 else T1 aborts |
| wound-wait | deadlock policy: If T1 wants something T2 has, T2 aborts if T1 has a higher priority else T1 waits |
| multiple-granularity lock | a lock that works on nested objects |
| intention share | lock that conflicts only with X |
| intention exclusive | lock that conflicts only with S and X |
| predicate locking | granting locks on all records that satisfy some kind of predicate |
| index locking | locking index pages containing data entries with a rating =1 |
| Thomas Write Rule | Rule saying that you can ignore a write if it know that will be overwritten before it is read again |
| stable storage | non-volatile storage that is redundant and with very high probability is protected from loss. |
| CLR | This is inserted before an action described by an update log record is undone. These are never undone and contain an undoNextLSN field |
| loser transaction | a transaction that is active at the time of a crash |