Relational Database and SQL

0.0(0)
studied byStudied by 0 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/137

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

138 Terms

1
New cards

The data can be defined as ________________.

raw fact that has meaning and can be measured

3 multiple choice options

2
New cards

Information is the result of ______________.

processing raw data to reveal its meaning

3 multiple choice options

3
New cards

The database should be designed to store all __________ that a business needs and be able to provide _______ that the user needs.

data, information

3 multiple choice options

4
New cards

In this book, you will learn how to develop a database to store raw data, and how to produce information by processing the data. In each chapter you will learn __________ and ____________.

database development, SQL

3 multiple choice options

5
New cards

A database is ____________.

a collection of organized data

3 multiple choice options

6
New cards

Which of the following databases is the most popular and focus of this book?

relational

3 multiple choice options

7
New cards

What type of database is not structured, and has no apparent relationships between records, thus making it necessary to read the entire file in order to find a specific record?

flat-file

3 multiple choice options

8
New cards

Data is organized into a tree-like structure. The relationship allows a parent table to have multiple children tables but a child table can only have one parent table. This is describing which type of database?

hierarchical

3 multiple choice options

9
New cards

If a database is for a tutoring center of a university, then the mini-world is the _____________.

tutoring center

3 multiple choice options

10
New cards

A database should be a(n) _____________ of the mini-world.

abstract

3 multiple choice options

11
New cards

The first step for a database designer is to understand the ____________.

mini-world

3 multiple choice options

12
New cards

The part of the real world the database is related to is known as the ____________.

mini-world

3 multiple choice options

13
New cards

Word processor software to your paper is like _________to databases.

DBMS

3 multiple choice options

14
New cards

Which of the following is NOT DBMS?

IBM

3 multiple choice options

15
New cards

The _____________ is the data that users are interested in.

user data

3 multiple choice options

16
New cards

THE DBMS uses ______ for the structure of the user data. It is data about data.

Metadata

3 multiple choice options

17
New cards

The word "relational" in relational database refers to a _____.

table

3 multiple choice options

18
New cards

In relational databases, a table contains one or more _______________.

records

3 multiple choice options

19
New cards

In relational databases, a record contains one or more __________.

fields

3 multiple choice options

20
New cards

A _________ is the tool that is required for working with a database.

DBMS

3 multiple choice options

21
New cards

The __________ includes the DBMS software together with the data itself. Sometimes, the applications are also included.

Database system

3 multiple choice options

22
New cards

Which of the following is a typical sequence when a user works with a database?

user > application > DBMS > user data

3 multiple choice options

23
New cards

The __________ usually works with DBMS directly by issuing __________, statements.

users, NOSQL

3 multiple choice options

24
New cards

What are the two meanings of schema in database concepts?

structure and container

3 multiple choice options

25
New cards

When a database schema is the ________ of the relational database.

blueprint

3 multiple choice options

26
New cards

When a database state changes, the database ___________ must be respected.

schemas

3 multiple choice options

27
New cards

One meaning of schema is a container that holds one or more __________.

database objects, such as tables and views

3 multiple choice options

28
New cards

Before the RDBMS era, the use of databases was very _____.

costly

3 multiple choice options

29
New cards

Which of the following was a problem for using databases before the RDBMS era?

it required highly trained programmers

3 multiple choice options

30
New cards

Which of the following was a problem for using databases before the RDBMS era?

a single program could only be tied to a single database, which made it difficult to have another program use the same data

3 multiple choice options

31
New cards

Who is usually considered the founder of the relational databases?

Dr. E.F. Codd of IBM

3 multiple choice options

32
New cards

The first commercial RDBMS was introduced by __________.

Oracle

3 multiple choice options

33
New cards

Which of the following is not a modern, popular challenger of the relational database?

hierarchical database

3 multiple choice options

34
New cards

Adding one ore more new records to a table or a view in SQL Server is what type of SQL command?

DML

2 multiple choice options

35
New cards

Creating a SQL Server database object such as a table, view, or stored procedure is related to what type of SQL command?

DDL

2 multiple choice options

36
New cards

According to the author of the book, why do we build models?

to better understand more complex real-world objects or events

3 multiple choice options

37
New cards

A model is ___________ a mini-world

an abstract of

3 multiple choice options

38
New cards

Which of the following is a characteristic of a good model?

The model must map the mini-world objects

3 multiple choice options

39
New cards

Which of the following is a characteristic of a good model?

The model should fit its purpose

3 multiple choice options

40
New cards

Which of the following is a characteristic of a good model?

The model is just an abstract; certain details are purposely ignored

3 multiple choice options

41
New cards

A data model has to include __________, which is the structure of the database, _________ that work on these constructs, and __________ for the data.

constructs, operations, constraints

3 multiple choice options

42
New cards

In a data model, the ___________ are entities and the relationships among the entities.

constructs

3 multiple choice options

43
New cards

In a data model, the _________ are specifications for how to insert or update a construct.

operations

3 multiple choice options

44
New cards

In a data model, the _________ are restrictions on data that allows the data to reflect the min-world more accurately.

constraints

3 multiple choice options

45
New cards

Which of the following is NOT a characteristic of a good model?

Engines

3 multiple choice options

46
New cards

Which of the following is NOT a concept of ER model?

blueprint

3 multiple choice options

47
New cards

The first step in data modeling is _____________.

documenting the business description

3 multiple choice options

48
New cards

The business description document usually includes _____________.

user expectations and criteria to measure success

3 multiple choice options

49
New cards

The business description serves as a _______.

communication tool between the customers and the developers

3 multiple choice options

50
New cards

A business description usually includes __________.

supporting documents

3 multiple choice options

51
New cards

The __________ is/are derived from the business description and focus on the policy and rules of the mini-world.

business rules

3 multiple choice options

52
New cards

Each business rule typically starts with _________.

singular noun

3 multiple choice options

53
New cards

Most business rules are paired with ____________.

two objects

3 multiple choice options

54
New cards

A(n) ________________ is a person, place, object, event, or concept in the mini-world about which we wish to develop the database.

entity

3 multiple choice options

55
New cards

A single occurrence of an entity type is ___________.

an entity instance

3 multiple choice options

56
New cards

The ________ is an entity type whose existence completely depends on another entity.

weak entity

3 multiple choice options

57
New cards

A department has several student clubs. The department needs a database to keep data about the clubs and students. Which of the following is NOT an entity in ERD?

department

3 multiple choice options

58
New cards

A course (an instance) has a prerequisite of another course (an instance). Both courses are from the same COURSE entity. The "a course may have one or more prerequisites" is a ___________ relationship.

unary

3 multiple choice options

59
New cards

An example of a __________ relationship is " a manager manages other employees." In this example, both managers and employees are from the EMPLOYEE entity.

unary

3 multiple choice options

60
New cards

An example of a __________ relationship is "a person is married to another person." Both are from the PERSON entity.

unary

3 multiple choice options

61
New cards

A ____________ relationship is a relationship between instances of two entity types. An example of such a relationship is "an instructor teaches zero or more course."

binary

3 multiple choice options

62
New cards

According to the author of our textbook, the ___ relationships are the most popular form of relationships. You will see many examples of such relationships throughout the book.

binary

3 multiple choice options

63
New cards

A ___ relationship is a relationship among instances of three entity types. For example, a supplier ships a product to a retailer.

ternary

3 multiple choice options

64
New cards

If an instructor can teach many courses and each course can be taught by only one instructor, this is a ________ relationship.

1:M

3 multiple choice options

65
New cards

If a student can take zero or many courses and each course must have at least one student. This is a ____________ relationship.

M:N

3 multiple choice options

66
New cards

If each student has one computer lab account and each computer lab account belongs to at most one student is an example of _____________ relationship

1:1

3 multiple choice options

67
New cards

If an entity can have zero instances in the relationship, it is __________. It is shown as __________ in ERD.

optional, small circle

3 multiple choice options

68
New cards

If an entity has one or many instances in the relationship it is _________. It is shown as _______ in the ERD..

Mandatory, a short vertical line

3 multiple choice options

69
New cards

Connectivity

the specifics of how two entities are related. showing their relationship to each other (i.e- 1:M, 1:1, M:N)

70
New cards

Cardinality

expresses the specific number of instances in an entity (0,1 to 1,1)

71
New cards

A ________ is an association between the instances of one ore more entity types. For example, Tom Smith (an instance of INSTRUCTOR) teaches Introduction to Computer Sciences (an instance of COURSE).

relationship

3 multiple choice options

72
New cards

How many entity types are in the relationship is called the __________ of relationship. Examples include unary, binary, or ternary.

degree

3 multiple choice options

73
New cards

The _________ of a relationship is about how many instances of entity are associated with each instance of the participating entity. For example, 1:1, 1:M, M:N)

connectivity

3 multiple choice options

74
New cards

The ________ of relationship shows the minimum and maximum entity instances possible in the relationship.

cardinality

3 multiple choice options

75
New cards

A relationship such as "a STUDENT takes a COURSE" can have a(n) _________ called final grade.

attribute

3 multiple choice options

76
New cards

In database design, an unweighted student GPA attribute has the _________ of between 0 and 4.0 for many schools.

domain

3 multiple choice options

77
New cards

The _______ are the properties used to describe an entity or a relationship. For example, an INSTRUCTOR entity may include the instructor ID, first name, last name.

attributes

3 multiple choice options

78
New cards

Each attribute has a set of possible values called a(n) __________.

domain

3 multiple choice options

79
New cards

Each attribute has a set value associated with it. For example, an instructor ID may be an integer, and the first name and last name should be a string of letters. Such a value set is called the attribute's ___________.

data type

3 multiple choice options

80
New cards

In ERD, an entity can have one or more attributes; A __________ can also have attributes.

relationship

3 multiple choice options

81
New cards

Different levels of abstraction can serve different purposes. Business users usually just need a _______ and _______ model, and don't need a ________ model.

conceptual, logical, physical

3 multiple choice options

82
New cards

A _______________ model will help the users and developers to define the scope of the project.

conceptual

3 multiple choice options

83
New cards

A __________ model will help users determine if all the data needed are in the model and if no extra data is included in the model.

logical

84
New cards

The _________ model focuses on why we need to model the data; e.g. student records must be accurate and kept for a long time.

contextual

3 multiple choice options

85
New cards

A model at the _____ level brings together all business stakeholders with their vision and strategy and their resulting priorities into a set of principles.

contextual

3 multiple choice options

86
New cards

All data models serve the purpose of __________.

communication between the developers and the customers.

3 multiple choice options

87
New cards

A model at the ________ level focuses on data requirements with entity and relationships, answering "what" questions, such as "what are the entities/objects you are going to model?

conceptual

3 multiple choice options

88
New cards

In a model at the __________ level, you start adding attributes to each entity and relationship. Determine attribute domains and decide which attributes can uniquely identity each record.

logical

3 multiple choice options

89
New cards

In a model at the __________ level, you first select the DBMS. In this book, you will use SQL Server. Then, add the data type for each field.

physical

3 multiple choice options

90
New cards

An SQL SELECT statement allows you to select _________ from a table.

one or more columns

3 multiple choice options

91
New cards

What does the following SQL statement do?

SELECT FirstName, LastName, GPA

FROM Admission.Student;

Retrieve all students' first names, last names, and GPA from the student table.

3 multiple choice options

92
New cards

The * in the SELECT clause of an SQL statement indicates selecting _________.

all columns

3 multiple choice options

93
New cards

What does the following SQL statement do?

SELECT DISTINCT Firstname, Lastname

FROM Admissions.Student;

Retrieve all students' first name, last name without duplicates for both first and last names.

3 multiple choice options

94
New cards

When the DBMS generates output, there is no guarantee that the result rows will appear in a certain order. You can use __________ clause to fix the problem

ORDER BY

3 multiple choice options

95
New cards

A ________ is a named property or characteristic of an entity or a relationship that is of interest to the user.

attribute

3 multiple choice options

96
New cards

After you build the conceptual model of a database, you can move on to the logical design by adding the _________ to the entity and relationships.

attributes

3 multiple choice options

97
New cards

In ERD, you use {LastName} to indicate a _____ attribute call LastName.

multivalued

3 multiple choice options

98
New cards

Only entities can have attributes.

False

99
New cards

A _________ attribute has a single atomic value that cannot be subdivided.

Simple

3 multiple choice options

100
New cards

A ________ attribute is the one that can be further subdivided to yield additional attributes.

composite

3 multiple choice options