Midterm Review Flashcards

(40 cards)

1
Q

What is a database system?

A
  • Computerized record-keeping system
  • A collection of programs to create and maintain database
  • Supports operations (ex. insert, retrieve, remove, or change data in database)
  • Components (ex. data, hardware, software, users)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What are the two types of databases?

A
  1. Single-user database: supports one user at a time
  2. Multiuser database: supports multiple users at the same time
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is a database?

A
  • Collection of persistent data that is used by the application systems of some given enterprise.
  • Collection of true propositions (ex. “Supplier S1 is located in London”)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What are the three elements that form a database?

A
  1. Entities
  2. Relationships
  3. Properties
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What are the three types of data?

A
  1. Static (e.g. part#, SIN)
  2. Dynamic (e.g. quantity, balance)
  3. Quasi-static (e.g. salary)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What are the 8 reasons to use a database?

A
  1. Shared data
  2. Reduced redundancy
  3. Reduced inconsistent data
  4. Transaction support
  5. Support for data integrity
  6. Security enforcement
  7. Support for standards
  8. Conflicting requirements can be met
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is shared data?

A

Data can be used to operate existing applications as well as develop new ones.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is data redundancy?

A

Keeping data in two or more places within a database or data storage system.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

How can data redundancy lead to data inconsistency?

A

When database updates are not propagated to all redundant data.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is data integrity?

A

The overall accuracy, completeness, and consistency of data.

For example:
- We shouldn’t have an employee working in a non-existent department.
- We shouldn’t have the number of hours entered as 400 instead of 40.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

How can database security be enforced?

A
  • Restricting unauthorized data
  • Different checks (security constraints) can be established for each type of access (retrieve, insert, delete, etc.)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What are the five functions of DBMSs?

A
  1. Data dictionary management
  2. Security management
  3. Multiuser access control
  4. Backup and recovery management
  5. Data integrity management
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What are some disadvantages of database systems?

A
  • Increased costs
  • Management complexity
  • Vendor dependence
  • Frequency upgrade/replacement cycles
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What is the difference between a database instance and database schema?

A

Schema: description of the database
Instance: database itself

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What is database schema?

A
  • Describes the database
  • Specified during the database design phase (not expected to change frequently)
  • Most data models have a notation for graphical representation of schema.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What is a database instance?

A
  • Refers to the data in the database at a particular moment in time.
  • Can correspond to a particular schema.
  • Every time we insert, delete, or update the value of a data item, we change one instance of database to another.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

What are the 3 levels in ANSI/SPARC architecture?

A
  1. Internal Level
  2. Conceptual Level
  3. External Level
18
Q

What is the internal level in ANSI/SPARC architecture?

A

Shows how data are stored inside the system. It is the closest level to the physical storage.

This level talks about database implementation and describes such things as file organization and access paths.

19
Q

What is the conceptual level in ANSI/SPARC architecture?

A

Deals with the modeling of the whole database. The conceptual schema of database is defined in this level.

20
Q

What is the external level in ANSI/SPARC architecture?

A

This level models a user-oriented description of part of the database. External schemas define individual users’ views at this level.

21
Q

What is database mapping?

A

The process of matching fields from one database to another. The key to providing data independence.

22
Q

What are the two types of data independence?

A
  1. Logical data independence
  2. Physical data independence
23
Q

What is logical data independence?

A

Ability to modify conceptual schema without changing external views or application programs. Provided by external/conceptual mapping.

24
Q

What is physical data independence?

A

Ability to modify internal or physical schema without changing conceptual or view level schema, or application programs.

25
What are the responsibilities of a database administrator?
- Participate in conceptual database design - Determines how to implement conceptual schema - Teach users, and help them report - Implement security and integrity - Implement unload/reload utilities - Monitor and tune database performance
26
What are the two DBMB sublanguages?
1. Data Definition Language (DDL): to define the database 2. Data Manipulation Language (DML): to manipulate data
27
What are the 3 stages in conceptual schema design?
Stage 1: Choice of model Stage 2: Normalization Stage 3: Optimization
28
What are the 3 elements of the Entity-Relationship Model?
- Entities - Relationships - Attributes
29
What is an entity?
A "thing in the real world with an independent existence". Can be strong (dominant, exist on their own) or weak (reliant, existence dependent on a strong entity)
30
What is a relationship?
Relationships associate entities with one another. The degree of a relationship type is the number of participating entity types (Binary or ternary relationship)
31
What are the 3 types of mapping constraints?
- One-to-one (1:1) - One-to-many (1:N) - Many-to-many (M:N)
32
What are the 2 types of participation constraints?
- Total participation (e.g. every department must be managed by a manager) - Partial participation (e.g. not every employee manages a department)
33
Simple vs. Composite Attributes
Simple: - Not divisible (ex. part#, weight) Composite: - Consists of several simple attributes - Example: Address > (Street Number, City, Postal Code)
34
Single-Valued vs. Multi-Valued Attributes
Attributes can contain multiple values. Ex. college_degrees, skills
35
Stored vs. Derived Attributes
Stored Attribute: actually held in database (ex. date_of_birth) Derived Attribute: derived through another attribute (ex. 'age' caluclated from date_of_birth)
36
What is specialization?
Process of defining a set of subclasses of an entity type. Ex. Employee (superclass) can be broken into full-time and part-time (subclasses)
37
What are the two types of specialization constraints?
1. Disjointness constraint 2. Completeness constraint
38
Two types of disjointness constraints:
1. Disjoint: an entity can be a member of at most one of the subclasses of the specialization. 2. Overlapping: the same entity can be a member of more than one subclass of the specialization.
39
Two types of completeness constraints:
1. Total: every entity in the superclass must be a member of some subclass in the specialization. 2. Partial: an entity may not belong to any of the subclasses in the specialization
40
Four types of specialization:
1. Disjoint, Total 2. Disjoint, Partial 3. Overlapping, Total 4. Overlapping, Partial