Beruflich Dokumente
Kultur Dokumente
Review your answers, feedback, and question scores below. An asterisk (*) indicates a
correct answer.
Section 11
(Answer all questions in this section)
1. In a physical data model, an attribute becomes a
_____________.
Table
Foreign Key
Constraint
Column (*)
Correct
2. In a physical data model, a relationship is represented as a
combination of: (Choose Two)
Columns
Tables
Unique Constraints (*)
Primary Key Constraints
Correct
4. To resolve a many to many relationship in a physical
model you create a/an ___________________?
Supertype
Intersection Table
Intersection Entity (*)
Subtype
Correct
6. The text below is an example of what constraint type?
The value in the manager_id column of the EMPLOYEES
table must match a value in the employee_id column in
the EMPLOYEES table.
Entity integrity
User-defined integrity
Column integrity
Referential integrity (*)
Correct
7. Entity integrity refers to:
True
False (*)
Correct
9. A foreign key cannot refer to a primary key in the same
table. True or False?
True
False (*)
Correct
10.A table must have a primary key. True or False?
True
False (*)
Correct
Review your answers, feedback, and question scores below. An asterisk (*) indicates a
correct answer.
Section 11
(Answer all questions in this section)
11.When mapping supertypes, relationships at the supertype
level transform as usual. Relationships at subtype level
are implemented as foreign keys, but the foreign key
columns all become mandatory. True or False?
True
False (*)
Correct
Section 12
(Answer all questions in this section)
12.The SQL statement ALTER TABLE EMPLOYEES
DELETE COLUMN SALARY is a valid statement. True
or False?
True
False (*)
Correct.
13.Once you have created a table, it is not possible to alter
the definition of it. If you need to add a new column you
must delete the table definition and create a new, correct
table. True or False?
True
False (*)
Correct.
14.What command will return data from the database to you?
FETCH
GET
SELECT (*)
RETURN
Correct.
15.What command can be used to create a new row in a table
in the database?
CREATE
NEW
ADD
INSERT (*)
Correct.
16.The DESCRIBE command returns all rows from a table.
True or False?
True
False (*)
Correct.
True
False (*)
Correct.
Section 15
(Answer all questions in this section)
19.Which SQL keyword specifies that an alias will be
substituted for a column name in the output of a SQL
query?
AS (*)
OR
AND
SUBSTITUTE
Correct.
20.Which SQL statement will return an error?
Review your answers, feedback, and question scores below. An asterisk (*) indicates a
correct answer.
Section 15
(Answer all questions in this section)
21.In which clause of a SELECT statement would you
specify the name of the table or tables being queried?
Joining only
Selection only
Projection only (*)
Projection and Selection
Correct.
23.In a SELECT clause, what is the result of 2 + 3 * 2?
6
8 (*)
10
13
Correct.
24.You want to create a list of all albums that have been
produced by the company. The list should include the title
of the album, the artist's name, and the date the album was
released. The ALBUMS table includes the following
columns:
ALB_TITLE VARCHAR2(150) NOT NULL
Section 16
(Answer all questions in this section)
25.You want to retrieve a list of customers whose last names
begin with the letters 'Fr' . Which keyword should you
include in the WHERE clause of your SELECT statement
to achieve the desired result?
AND
IN
BETWEEN
LIKE (*)
Correct.
26.You want to determine the orders that have been placed
by customers who reside in the city of Chicago. You write
this partial SELECT statement:
SELECT orderid, orderdate, total
FROM orders;
What should you include in your SELECT statement to
achieve the desired results?
AND city = Chicago;
AND city = 'Chicago';
% (*)
~
#
*
Correct.
28.Which of the following commands will display the last
name concatenated with the job ID from the employees
table, separated by a comma and space, and label the
resulting column "Employee and Title"?
*
/
+
|| (*)
Correct.
30.You need to display employees whose salary is in the
range of 10000 through 25000 for employees in
department 50 . What does the WHERE clause look like?
_
% (*)
#
&
Correct.
32.Which clause would you include in a SELECT statement
to restrict the data returned to only the employees in
department 10?
WHERE (*)
FROM
SELECT
IS
Correct.
33.Which comparison operator searches for a specified
character pattern?
IN
LIKE (*)
BETWEEN...AND...
IS NULL
Correct.
34.Which of the following elements cannot be included in a
WHERE clause?
Section 17
(Answer all questions in this section)
37.Which statement about the logical operators is true?
HAVING
Correct.
39.Which comparison condition means "Less Than or Equal
To"?
"=)"
"+<"
">="
"<=" (*)
Correct.
40.Which statement about the default sort order is true?
19
No rows will be returned
100, 101, 102, 103, 104, 107, 124, 141, 142, 143,
144, 149 (*)
200, 201, 202, 203, 204, 205, 206
Correct.
45.Evaluate this SELECT statement:
SELECT last_name, first_name, salary
FROM employees;
How will the results of this query be sorted?
The database will display the rows in whatever order
it finds it in the database, so no particular order. (*)
Correct.
50.The EMPLOYEES table contains these columns:
EMPLOYEE_ID NUMBER(9) PK
LAST_NAME VARCHAR2(25)
FIRST_NAME VARCHAR2(25)
DEPARTMENT_ID NUMBER(9)
Compare these two SQL statements:
1.
SELECT DISTINCT department_id DEPT, last_name,
first_name
FROM employees
ORDER BY department_id;
2.
SELECT department_id DEPT, last_name, first_name
FROM employees
ORDER BY DEPT;
How will the results differ?
One of the statements will return a syntax error.
One of the statements will eliminate all duplicate
DEPARTMENT_ID values.
There is no difference in the result between the two
statements.
The statements will sort on different column values.
(*)
Incorrect! See Section 17 Lesson 3.