Differential Buffer

Abstract

The database architecture discussed so far was optimized for read operations. In the previously described approach an insert of a single tuple can force a restructuring of the whole table if a new attribute value occurs and the dictionary has to be resorted. To overcome this problem, we will introduce the differential buffer in this chapter.

Self Test Questions

A buffer where different results for one and the same query are stored for later usage

(c)

A dedicated storage area in the database where inserts, updates and deletions are buffered

(d)

A buffer where queries are buffered until there is an idle CPU that takes one new task over.

2.

Performance of the Differential Buffer

Why might the performance of read queries decrease, if a differential buffer is used?

(a)

Because only one query at a time can be answered by using the differential buffer

(b)

Because read queries have to go against the main store and the differential buffer, which is write-optimized

(c)

Because inserts collected in the differential buffer have to be merged into the main store every time a read query comes in

(d)

Because the CPU cannot perform the query before the differential buffer is full.

3.

Querying the Differential Buffer

If we use a differential buffer, we have the problem that several tuples belonging to one real world entry might be present in the main store as well as in the differential buffer. How did we solve this problem?

(a)

This statement is completely wrong because multiple tuples for one real world entry must never exist

(b)

All attributes of every doubled occurrence are set to NULL in the compressed main store.

(c)

We introduced a validity bit

(d)

We use a specialized garbage collector that just keeps the most recent entry.