Uploaded by nahhhmeannn

database design exam1 study guide

advertisement
Chapter 1
1. What is a DBMS, how is it useful, and how is it important in today's society?
 Collection of programs


Manages the database structure
Controls access to data stored in the database

intermediary between the user and the database

Enables data to be shared

Presents the end user with an integrated view of data

Provides more efficient and effective data management

Improves sharing, security, integration, access, decision-making,
productivity, etc.
2. What are some of the feature sets/capabilities of a database?

Enables data to be shared

Presents the end user with an integrated view of data

Provides more efficient and effective data management

Improves sharing, security, integration, access, decision-making,
productivity, etc.
3. What file formats can be considered a database(at least 3)?
.xlsx(excel), .xml(extensible markup for data about data), .ics(iCal relationally links date to events , people and places)
4. Be able to list some of the associated data types and define them (numerical alphabetical etc)
5. Chapter 1 slide 17 will have some questions from that slide
 Problems with file systems challenge the types of information that
can be created from data as well as information accuracy


Lengthy development times
Difficulty of getting quick answers



Complex system administration
Lack of security and limited data sharing
Extensive programming

6. Chapter 1 slide 18 what is the difference between structural dependence and independence
 Structural dependence


Access to a file is dependent on its own structure
All file system programs are modified to conform to a new file structure

Structural independence

File structure is changed without affecting the application’s ability to
access the data

7. Chapter 1 slide 27-29 study database functions
 Data dictionary management

Data dictionary: stores definitions of data elements and their relationships

Data storage management

Performance tuning ensures efficient performance

Data transformation and presentation

Data is formatted to conform to logical expectations

Security management

Enforces user security and data privacy
 Multiuser access control

Sophisticated algorithms ensure that multiple users can access the
database concurrently without compromising its integrity

Backup and recovery management

Enables recovery of the database after a failure

Data integrity management

Minimizes redundancy and maximizes consistency
 Database access languages and application programming interfaces

Query language: lets the user specify what must be done without having
to specify how

Structured Query Language (SQL): de facto query language and data access
standard supported by the majority of DBMS vendors

Database communication interfaces

Accept end-user requests via multiple, different network environments
Chapter 16
1. Chapter 16 slide 5 Be able to list and define dirty data, data quality, and dmdm
2. Chapter 16 slide 16-18 Be able to list some of the technical and managerial roles of DBA
3. Chapter 16 slide 19-21 and 23 study security elements for true/false and multiple choice
Chapter 3
1. Be able to define the relational database model, what it does for us and its value.
 Relational database model enables logical representation of the
data and its relationships

Logical simplicity yields simple and effective database design
methodologies

The logical view is facilitated by the creation of data relationships based on
a logical construct called a relation
2. Slide 4 Be able to list some of the characteristics of relational table

Table 3.1

Characteristics of a Relational Table

1

A table is perceived as a two-dimensional structure composed of rows and columns.

2

Each table row (tuple) represents a single entity occurrence within the entity set.

3

Each table column represents an attribute, and each column has a distinct name.

4

Each intersection of a row and column represents a single data value.

5

All values in a column must conform to the same data format.

6

Each column has a specific range of values known as the attribute domain.

7

The order of the rows and columns is immaterial to the DBMS.

8

Each table must have an attribute or combination of attributes that uniquely identifies
each row.
3. What is a primary key used for and why is it important
 attribute or combination of attributes that uniquely identifies a
row
 Ensure that each row in a table is uniquely identifiable

Establish relationships among tables and to ensure the integrity of the
data
4. What is a foreign key used for and why is it important
 Foreign key: primary key of one table that has been placed into another
table to create a common attribute
5. Slide 7 for true false questions

 Table 3.3
 Relational Database Keys

Key Type

Definition

Superkey

An attribute or combination of attributes that uniquely identifies each row in a table.

Candidate
key

A minimal (irreducible) superkey; a superkey that does not contain a subset of
attributes that is itself a superkey.

Primary key

A candidate key selected to uniquely identify all other attribute values in any given row;
cannot contain null entries.

Foreign key

An attribute or combination of attributes in one table whose values must either match
the primary key in another table or be null.

Secondary
key

An attribute or combination of attributes used strictly for data retrieval purposes.


6. what are business rules used for and why are they important?
7. what are some integrity rules used for and why are they important
 Relational database integrity rules are very important to good
database design

Relational database management systems (RDBMSs) enforce integrity
rules automatically

Much safer to make sure the application design conforms to entity and referential
integrity rules

Table 3.4

Integrity Rules

Entity Integrity

Description

Requirement

All primary key entries are unique, and no part of a primary key may be null.

Purpose


Each row will have a unique identity, and foreign key values can properly
reference primary key values.

Example


No invoice can have a duplicate number, nor can it be null; in short,
all invoices are uniquely identified by their invoice number.

Referential
Integrity

Description

Requirement




A foreign key may have either a null entry, as long as it is not a part of its table’s
primary key, or an entry that matches the primary key value in a table to which
it is related (every non-null foreign key value must reference an existing primary
key value).

Purpose




It is possible for an attribute not to have a corresponding value, but it will be
impossible to have an invalid entry; the enforcement of the referential
integrity rule makes it impossible to delete a row in one table whose primary
key has mandatory matching foreign key values in another table.

Example


A customer might not yet have an assigned sales representative (number), but it
will be impossible to have an invalid sales representative (number).


8. slide 15-25 be able to list and define some of the relational set operators

SELECT is the command to show all rows in a table. It can be used to select only specific data from the table that
meets certain criteria. This command is also referred to as the Restrict command.
UNION. It combines all of the rows in one table with all of the rows in another table except for the duplicate tuples. The tables
are required to have the same attribute characteristics for the Union command to work. The tables must be union-compatible
which means that two tables being used have the same amount of columns and the columns have the same names, and also
need to share the same domain.
INTERSECT is the second SQL command that takes two tables and combines only the rows that appear in both tables. The
tables must be union-compatible to be able to use the Intersect command or else it won't work.
DIFFERENCE in another SQL command that gets all rows in one table that are not found in the other table. Basically it
subracts one table from the other table to leave only the attributes that are not the same in both tables. For this command to
work both tables must be union-compatible.
PRODUCT command would show all possible pairs of rows from both tables being used. This command can also be referred
to as the Cartesian Product.
PROJECT is the command that gives all values for certian attributes specified after the command. It shows a vertical view of
the given table.
JOIN takes two or more tables and combines them into one table. This can be used in combination with other commands to
get specific information. There are several types of the Join command. The Natural Join, Equijion, Theta Join, Left Outer Join
and Right Outer Join.

9. what is a data dictionary used for and why is it important
 Description of all tables in the database created by the user and designer

10.
what is a system catalog used for and why is it important
 System data dictionary that describes all objects within the database

11.
slide 27-30 be able to identify one to one, one to many, and many to many relationships from images Reread this
section in chapter
12.
How can we reduce data redundancy through the use of foreign keys
common attributes are shared by the tables to avoid repetition
13.
What is an index used for and why is it important
 Orderly arrangement to logically access rows in a table

Index key: index’s reference point that leads to data location identified by
the key

Unique index: index key can have only one pointer value associated with it

Each index is associated with only one table

The index key can have multiple attributes
Chapter 7 - Labeled as Structure Query Language on Blackboard
1. Slide 3 Be able to list and define some of the categories of SQL functions list on slide, def in book
 Data definition language (DDL)-is a computer language used to create and modify the
structure of database objects in a database. These database objects include views, schemas, tables,
indexes, etc.

Data manipulation language (DML)-

Transaction control language (TCL)-This command is used to manage the changes made
A data manipulation language (DML) is a computer
programming language used for adding (inserting), deleting, and modifying (updating) data in a database.
by DML statements. TCL allows the statements to be grouped together into logical transactions.

Data control language (DCL)-is a syntax similar to a computer programming language used to control
access to data stored in a database (Authorization). Grant and revoke commands
2. Data Definition commands
3. Table 7.2
4. SQL Data Definition Commands
5.
6. Command or Option7. Description
8. Covered
9. CREATE SCHEMA
10.
AUTHORIZATION
Creates a database schema
11.
ter 8
Chap
12.
CREATE
TABLE
Creates a new table in the user’s database schema
14.
ter 8
Chap
13.
15.
NOT NULL
16.
Ensures that a column will not have null values
17.
ter 8
Chap
18.
UNIQUE 19.
Ensures that a column will not have duplicate values
20.
ter 8
Chap
21.
KEY
PRIMARY22.
Defines a primary key for a table
23.
ter 8
Chap
24.
KEY
FOREIGN25.
Defines a foreign key for a table
26.
ter 8
Chap
27.
DEFAULT28.
Defines a default value for a column (when no value is given)
29.
ter 8
Chap
30.
CHECK 31.
Validates data in an attribute
32.
ter 8
Chap
Creates an index for a table
35.
ter 8
Chap
33.
CREATE
INDEX
34.
36.
CREATE
VIEW
37.
Creates a dynamic subset of rows and columns from one or more
38.
tables
ter 8
Chap
39.
ALTER
TABLE
40.
Modifies a table’s definition (adds, modifies, or deletes attributes 41.
or
constraints)
ter 8
Chap
42.
CREATE
TABLE AS
43.
Creates a new table based on a query in the user’s database schema 44.
ter 8
Chap
45.
DROP
TABLE
46.
Permanently deletes a table (and its data)
47.
ter 8
Chap
48.
DROP
INDEX
49.
Permanently deletes an index
50.
ter 8
Chap
Permanently deletes a view
53.
ter 8
Chap
51.
DROP VIEW
52.
54.
What are some transactional control and data control language commands
55.
56.

 COMMIT

Permanently saves data changes



Restores data to its original values

ROLLBACK
Slide 8 Be able to list and define some of the basic select queries you can do select, from, where, group by
Slide 37 What are some of the best practices when crafting select queries
 SELECT: specifies the attributes to be returned by the query

FROM: specifies the table(s) from which the data will be retrieved

WHERE: filters the rows of data based on provided criteria

GROUP BY: groups the rows of data into collections based on sharing the
same values in one or more attributes

HAVING: filters the groups formed in the GROUP BY clause based on
provided criteria

ORDER BY: sorts the final query result rows in ascending or descending
order based on the values of one or more attributes
57.
Be able to tell the differences between different types of joins
 Inner joins return only rows from the tables that match on a common
value

Outer joins return the same matched rows as the inner join, plus
unmatched rows from one table or the other
58.
59.
Clause options such as =, <, > ex This symbol (=) means greater than true or false
Slides 27 special operators
 BETWEEN




60.
61.
62.
IN
LIKE
IS NULL
NOT
Logical operators and, or, not
Know some of the basic aggregate functions min max
Slide 31 Know some key characteristics of sub queries
 A subquery is a query (SELECT statement) inside another query






A subquery is normally expressed inside parentheses
The first query in the SQL statement is known as the outer query
The query inside the SQL statement is known as the inner query
The inner query is executed first
The output of an inner query is used as the input for the outer query
The entire SQL statement is sometimes referred to as a nested query
Chapter 15
1. What is obdc, rdo, and eao used for and why are they important?
 Open Database Connectivity (ODBC): Microsoft’s implementation
of a superset of SQL Access Group Call Level Interface (CLI)
standard for database access

Widely supported database connectivity interface

Allows Windows application to access relational data sources by using SQL
via standard application programming interface (API)
 Data Access Objects (DAO): object-oriented API used to access
desktop databases such as MS Access and FileMaker Pro

Provides an optimized interface that expose functionality of Jet data
engine to programmers
 Remote Data Objects (RDO): higher-level object-oriented
application interface used to access remote database servers

Optimized to deal with server-based databases
 Dynamic-link libraries (DLLs): implements ODBC, DAO, and RDO as
shared code that is dynamically linked to the Windows operating
environment

Components of ODBC architecture

High-level ODBC API through which application programs access ODBC
functionality

Driver manager that is in charge of managing all database connections

ODBC driver that communicates directly to DBMS
2. What is a ADO used for and why is it important
 ActiveX Data Objects (ADO) provide:

High-level application-oriented interface to interact with OLE-DB, DAO, and
RDO

Unified interface to access data from any programming language that uses
the underlying OLE-DB objects
3. What are some advantages of JDC
 Application programming interface that allows a Java program to
interact with a wide range of data sources

Advantages of JDBC

Company can leverage existing technology and personnel training

Direct access to database server or access via database middleware

Programmers can use their SQL skills to manipulate the data in the
company's databases

Provides a way to connect to databases through an ODBC driver
4. Slide 31 What is the difference between cloud implementation types and define them
 Public cloud

Built by a third-party organization to sell cloud services to the general
public

Private cloud

Built by an organization for the sole purpose of servicing its own needs

Community cloud

Built by and for a specific group of organizations that share a common
trade

5. Slide 33 Be able to list some of the types of cloud services platform as a service, infrastructure as a service and examples
6. Slide 34 good and bad of cloud services
Table 15.4: Advantages
Computing
Advantage
and
Disadvantages
of
Cloud
Disadvantage
Low initial cost of entry. Cloud computing has lower costs of Issues of security, privacy, and compliance. Trusting
entry when compared with the alternative of building in house. sensitive company data to external entities is
difficult for most data-cautious organizations.
Scalability/elasticity. It is easy to add and remove resources on Hidden costs of implementation and operation. It is
demand.
hard to estimate bandwidth and data migration costs.
Support for mobile computing. Cloud computing providers Data migration is a difficult and lengthy process.
support multiple types of mobile computing devices.
Migrating large amounts of data to and from the
cloud infrastructure can be difficult and
time-consuming.
Ubiquitous access. Consumers can access the cloud resources Complex licensing schemes. Organizations that
from anywhere at any time, as long as they have Internet implement cloud services are faced with complex
access.
licensing schemes and complicated service-level
agreements.
High reliability and performance. Cloud providers build solid Loss of ownership and control. Companies that use
infrastructures that otherwise are difficult for the average cloud services are no longer in complete control of
organization to leverage.
their data. What is the responsibility of the cloud
provider if data are breached? Can the vendor use
your data without your consent?
Fast provisioning. Resources can be provisioned on demand in Organization culture. End users tend to be resistant
a matter of minutes with minimal effort.
to change. Do the savings justify being dependent on
a single provider? Will the cloud provider be around
in 10 years?
Managed infrastructure. Most cloud implementations are Difficult integration with internal IT system.
managed by dedicated internal or external staff. This allows the Configuring the cloud services to integrate
organization’s IT staff to focus on other areas.
transparently with internal authentication and other
internal services could be a daunting task.
Download