Sei sulla pagina 1di 20

7/31/2019 Finals


Dashboard My courses CS-352-LEC-1913T Week 14: Final Exam Finals


Question 1 This is a join clause used when the columns in two or more

Answer saved tables have the same but of different data type.
Marked out of
 1.00 Select one:
a. ON

b. Inner Join
 c. Outer Join

d. Using

Clear my choice

Question 2 This is a kind of mechanism, which liberalizes itself from actual


Answer saved data stored on the disk.
Marked out of
1.00 Select one:
a. Physical Data Independence

b. Logical Data Independence

c. Physical Database Schema

d. Logical Database Schema

Clear my choice

Question 3 This is used to quality ambiguous column when joining two or


Answer saved more tables.
Marked out of
1.00 Select one:
a. Column Alias

b. Table Alias

c. Table Prefixes

d. Column Prefixes

Clear my choice

Question 4 This is a schema that pertains to the actual storage of data and
Answer saved its form of storage like files, indices.
Marked out of
1.00 Select one:
a. Physical Database Schema

b. Logical Database Schema

c. Historical Database Schema

d. Scientific Database Schema

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 1/20
7/31/2019 Finals

Question 5 SELECT employees.employee_id,


Answer saved employees.lastname,employees.department_id,
Marked out of departments.department_id,departments.location_id
1.00 FROM employees FULL OUTER JOIN departments

ON (WHERE employees.department_id =
departments.department_id);

Select one:

a. The given statement is an Equijoin

 b. The given statement is Outer Join

c. The given statement would cause Cartesian or Cross Join


 d. The given statement is not a valid join condition or is
incorrect

Clear my choice

 Question 6 Which of the following is not true about complex view when
Answer saved using INSERT statement?
Marked out of
1.00 Select one:
a. All of the choices

b. You cannot add data through a view if the view


includes:Group functions

c. You cannot add data through a view if the view includes


the pseudocolumn ROWNUM keyword

d. You cannot modify data in a view if it contains a GROUP


BY clause

Clear my choice

Question 7 Which of the following is not true about complex view when
Answer saved using DELETE statement?
Marked out of
1.00 Select one:
a. All of the choices

b. You cannot modify data in a view if it contains group


functions

c. You cannot modify data in a view if it contains a distinct


keyword.

d. You cannot modify data in a view if it contains a GROUP


BY clause

Clear my choice

Question 8 Which of the following is not part of comparison condition used


Answer saved in multiple row subquery.
Marked out of
1.00 Select one:
a. ALL

b. =

c. IN

d. ANY

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 2/20
7/31/2019 Finals

Question 9 Which of the following is the correct example of an entity.


Answer saved

Marked out of Select one:


1.00
 a. Lastname

b. SSS id
 c. Workers

 d. Accession_no

Clear my choice

 Question 10 Supposed that table: Workers and Employees is consists of the


Answer saved following values.
 Marked out of What will be the output if the user uses this PL/SQL.
1.00
 DELETE FROM WORKERS
WHERE LASTNAME = (SELECT LASTNAME FROM EMPLOYEES WHERE
 LASTNAME=Cruz’)

Select one:
a. Employee in Employees table with lastname equal to Cruz
will be deleted.

b. 0 rows are deleted in Employees table

c. Employee in Workers table with lastname equal to Cruz


will be deleted.

d. 0 rows are deleted in Workers table

Clear my choice

Question 11 Which of the following is not part of multiple row subqueries?


Answer saved

Marked out of Select one:


1.00
a. MAX

b. ANY

c. ALL

d. IN

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 3/20
7/31/2019 Finals

Question 12 It is join between two tables that return the result of an Inner
Answer saved Join as well as the results of Left and Right joins.
Marked out of
1.00 Select one:

a. Inner Join

 b. Outer Join

c. ON

d. Using

 Clear my choice


Question 13 This of the following is not part of comparison condition used in
 Answer saved single row subquery.
Marked out of
 1.00 Select one:
a. IN

b. >

c. <

d. <>

Clear my choice

Question 14 Which of the following joins are mutually exclusive.


Answer saved

Marked out of Select one:


1.00
a. Inner join and Outer Join

b. IN and Using clause

c. Left and Right Outer join

d. Natural Join and Using clause

Clear my choice

Question 15 It is a join of two or more table that returns only matched rows.
Answer saved

Marked out of Select one:


1.00
a. Using

b. Inner Join

c. ON

d. Outer Join

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 4/20
7/31/2019 Finals

Question 16 Supposed that table: Workers and Employees is consists of the


Answer saved following values.
Marked out of
1.00


What will be the output if the user uses this PL/SQL.

DELETE FROM WORKERS

 WHERE LASTNAME = (SELECT LASTNAME FROM EMPLOYEES WHERE


LASTNAME=Cruz’)

Select one:
a. 0 rows are deleted in Employees table

b. Employee in Workers table with lastname equal to Cruz


will be deleted.

c. Employee in Employees table with lastname equal to Cruz


will be deleted.

d. 0 rows are deleted in Workers table

Clear my choice

Question 17 SELECT emp.employee_id,


Answer saved employees.lastname,emp.department_id,
Marked out of dept.department_id,dept.location_id
1.00 FROM employees emp, departments dept
WHERE emp.department_id = dept.department_id;

Select one:
a. The given statement is an Equijoin

b. The given statement would cause Cartesian or Cross Join

c. The given statement is Outer Join

d. The given statement is not a valid join condition or is


incorrect

Clear my choice

Question 18 Which of the following are the two types of subquery. 


Answer saved

Marked out of Select one:


1.00
a. Multiple row and one row subquery

b. Single row and multiple row subquery

c. Many row and single subquery

d. One and many row subquery

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 5/20
7/31/2019 Finals

Question 19 This is a join clause used when the columns in two or more
Answer saved tables have the same but of different data type.
Marked out of
1.00 Select one:

a. Using

 b. ON

c. Outer Join

d. Inner Join

 Clear my choice


Question 20 SELECT employees.employee_id,
 Answer saved employees.lastname,employees.department_id,
Marked out of departments.department_id,departments.location_id
 1.00 FROM employees, departments
WHERE employees.department_id (+)=
 departments.department_id;

Select one:
a. The given statement would cause Cartesian or Cross Join

b. The given statement is Outer Join

c. The given statement is an Equijoin

d. The given statement is not a valid join condition or is


incorrect

Clear my choice

Question 21 SELECT employees.employee_id,


Answer saved employees.lastname,employees.department_id,
Marked out of departments.department_id,departments.location_id
1.00 FROM employees JOIN departments
ON( employees.department_id (+)=
departments.department_id);

Select one:
a. The given statement would cause Cartesian or Cross Join

b. The given statement is not a valid join condition or is


incorrect

c. The given statement is Outer Join

d. The given statement is an Equijoin

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 6/20
7/31/2019 Finals

Question 22

Answer saved

Marked out of
1.00

Based on the table EMPLOYEES, DEPARTMENTS and LOCATIONS.


From the given select statement below: What is/are the full
name of employee whose LOCATION_ID is equal to 1700?
SELECT (LASTNAME||','||FIRSTNAME) AS "FULL NAME", DEPARTMENT_ID,
DEPARTMENT_NAME, LOCATION_ID
FROM EMPLOYEES
NATURAL JOIN DEPARTMENTS;
 

Select one:
a. GIETZ, WILLIAM

b. KOCHAR, NENA and LEX, DE HAAN

c. FAY, PAT and DAVIES, CURTIS

d. LORENTZ, DIANA

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 7/20
7/31/2019 Finals

Question 23 Supposed that table: Workers and Employees is consists of the


Answer saved following values.
Marked out of
Which of the following is the correct example of copying data
1.00
 from WORKERS table to EMPLOYEES table where the status is
equal to ‘Regular’?

 Select one:
a. INSERT INTO EMPLOYEES(ID, LASTNAME, DEPARTMENT)
SELECT *
FROM WORKERS
WHERE STATUS = ‘Regular’;

b. INSERT INTO EMPLOYEES (ID, LASTNAME, DEPARTMENT)


VALUES (SELECT ID, LASTNAME, DEPARTMENT
FROM WORKERS
WHERE STATUS = ‘Regular’);

c. INSERT INTO EMPLOYEES VALUES (ID, LASTNAME, DEPARTMENT)


SELECT ID, LASTNAME, DEPARTMENT
FROM WORKERS
WHERE STATUS = ‘Regular’;

d. INSERT INTO EMPLOYEES(ID, LASTNAME, DEPARTMENT)


SELECT ID, LASTNAME, DEPARTMENT
FROM WORKERS
WHERE STATUS = ‘Regular’;

Clear my choice

Question 24 A join condition that is based on all the columns in two or more
Answer saved table that have the same name.
Marked out of
1.00 Select one:
a. Cartesian Product

b. Self-Join

c. Natural Join

d. Cross Join

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 8/20
7/31/2019 Finals

Question 25
Answer saved

Marked out of
1.00

 If WITH CHECK OPTION is added on the view (see sample code


below) what is/are the restriction?
 CREATE OR REPLACE VIEW VIEW STUD_VIEW (USN_ID, LASTNAME,
FIRSTNAME, COURSE)
 AS (SELECT USN_ID, LASTNAME, FIRSTNAME, COURSE
FROM STUDENTS

WHERE COURSE = ‘BSCS’

 WITH CHECK OPTION CONSTRAINT STUD_VIEW_CK;

 Select one:
a. NO DML operations allowed on this view.

b. SELECT statement is not allowed on this view

c. It restricts the users to add a value where course is not


equal to BSCS

d. It restricts the users to add a value where course is equal


to BSCS only

Clear my choice

Question 26 Which of the following is not part of single to subqueries?


Answer saved

Marked out of Select one:


1.00
a. =

b. >=

c. <>

d. IN

Clear my choice

Question 27 SELECT EMPLOYEES.EMPLOYEE_ID,


Answer saved EMPLOYEES.LASTNAME,EMPLOYEES.DEPARTMENT_ID,DEPARTMENTS.D
Marked out of EPARTMENT_ID,DEPARTMENTS.LOCATION_ID
1.00
FROM EMPLOYEES JOIN DEPARTMENTS
ON( EMPLOYEES.DEPARTMENT_ID (+)=
DEPARTMENTS.DEPARTMENT_ID);

Select one:
a. The given statement is Outer Join

b. The given statement would case Cartesian or Cross Join

c. he given statement is not a valid join condition or is


incorrect

d. The given statement is an Equijoin

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 9/20
7/31/2019 Finals

Question 28 Supposed that table: Workers and Employees is consists of the


Answer saved following values.
Marked out of What will be the output if the user uses this PL/SQL.
1.00
 UPDATE EMPLOYEES

SET LASTNAME = (SELECT LASTNAME FROM WORKERS WHERE


 LASTNAME=’Soriano’)
WHERE ID=105;

Select one:
a. All Workers lastname will be set to NULL

b. The lastname of Cruz from Employees table will be set to


Soriano

c. The values of Employee with ID number 105 will be deleted

d. The lastname of Cruz from Employees table will be set to


NULL

Clear my choice

Question 29
Answer saved

Marked out of
1.00

Refer to the table AUTHORS and COPY_AUTHORS (Note during the


creation of view the condition added is YR_PUBLISHED=2010).
Supposed that the user update the YR_PUBLISHED of book OS to
from 2010 to 2010 as shown below what is/are the possible
output on both table and view?
UPDATE COPY_AUTHORS

SET YR_PUBLISHED = 2016


WHERE BOOK='OS';

Select one:
a. The record of book OS will be removed in the
COPY_AUTHORS view since its YR_PUBLIHED is updated to 2016

b. The record of book OS YR_PUBLISHED will be updated from


2010 to 2016 on COPY_AUTHORS view only.

c. The record of book OS YR_PUBLISHED will be updated from


2010 to NULL both on COPY_AUTHORS view and AUTHORS
table.

d. The record of book OS YR_PUBLISHED will be updated from


2010 to 2016 on AUTHORS table only.

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 10/20
7/31/2019 Finals

Question 30 This is a jpin clause that produces a cross-product of two or


Answer saved more tables.
Marked out of
1.00 Select one:

a. Natural Join

 b. Cross Join

c. Cartesian Product

d. Self-Join

 Clear my choice


Question 31 Which of the following is the correct example of creating a
 Answer saved subquery that will copy all values from employees table to
Marked out of workers where job_id is equal to ST_CLERK;
 1.00

Select one:
 a. INSERT INTO WORKERS
SELECT * FROM EMPLOYEES
WHERE JOB_ID = ‘ST_CLERK’;

b. INSERT INTO WORKERS


(SELECT ALL FROM EMPLOYEES
WHERE JOB_ID = ‘ST_CLERK’;

c. INSERT INTO WORKERS


(SELECT * FROM EMPLOYEES
WHERE JOB_ID = ‘ST_CLERK’);

d. INSERT INTO WORKERS


(SELECT * FROM EMPLOYEES
WHERE JOB_ID = ST_CLERK);

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 11/20
7/31/2019 Finals

Question 32
Answer saved

Marked out of
1.00

Based on the table EMPLOYEES, DEPARTMENTS and LOCATIONS.


From the given select statement below: What is the address of
employee under the department_name IT?
SELECT STREET_ADDRESS, CITY, DEPARTMENT_NAME, LOCATION_ID
FROM DEPARTMENTS

JOIN LOCATIONS
USING (LOCATION_ID);

Select one:
a. MAGDALENCENTER

b. 2014 JABBERWACKY

c. 460 RDBLOOR SY

d. 2004 CHARADE RD

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 12/20
7/31/2019 Finals

Question 33 SELECT employees.employee_id,


Answer saved employees.lastname,employees.department_id,
Marked out of departments.department_id,departments.location_id
1.00 FROM employees, departments

WHERE employees.department_id IN (50, 60, 90);

 Select one:
a. The given statement is not a valid join condition or is

incorrect

 b. The given statement is an Equijoin

c. The given statement would cause Cartesian or Cross Join


 d. The given statement is Outer Join

 Clear my choice


Question 34 SELECT employees.employee_id,
 Answer saved employees.lastname,employees.department_id,
Marked out of departments.department_id,departments.location_id FROM
1.00 employees JOIN departments WHERE employees.department_id
= departments.department_id;

Select one:
a. The given statement would cause Cartesian or Cross Join

b. The given statement is not a valid join condition or is


incorrect

c. The given statement is Outer Join

d. The given statement is an Equijoin

Clear my choice

Question 35 It is an attribute or collection of attributes that uniquely


Answer saved identifies an entity among entity set.
Marked out of
1.00 Select one:
a. Candidate Key

b. Super Key

c. Primary Key

d. Key

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 13/20
7/31/2019 Finals

Question 36 Which of the following is the correct example of creating a


Answer saved subquery that copy the values from employees table to workers
Marked out of table?
1.00

Select one:
a. INSERT INTO WORKERS(ID, NAME, POSITION)

SELECT (ID, NAME, POSITION
FROM EMPLOYEES);

b. INSERT INTO WORKERS(ID, NAME, POSITION)
 SELECT (ID, NAME, JOB_TITLE
FROM EMPLOYEES);

 c. INSERT INTO WORKERS(ID, NAME, POSITION)


VALUES (ID, NAME, POSITION
 FROM EMPLOYEES);

d. INSERT INTO WORKERS(ID, NAME, POSITION)


 FROM EMPLOYEES;

Clear my choice

Question 37 Which of the following is not true about complex view when
Answer saved using UPDATE statement?
Marked out of
1.00 Select one:
a. All of the choices

b. You cannot modify data in a view if it contains column


defined expression

c. You cannot modify data in a view if it contains a GROUP BY


clause

d. You cannot modify data in a view if it contains group


functions

Clear my choice

Question 38 SELECT EMPLOYEES.EMPLOYEE_ID,


Answer saved EMPLOYEES.LASTNAME,EMPLOYEES.DEPARTMENT_ID,DEPARTMENTS.D
Marked out of EPARTMENT_ID,DEPARTMENTS.LOCATION_ID
1.00
FROM EMPLOYEES RIGHT OUTER JOIN DEPARTMENTS
ON( EMPLOYEES.DEPARTMENT_ID = DEPARTMENTS.DEPARTMENT_ID);

Select one:
a. The given statement is Outer Join

b. The given statement is not a valid join condition or is


incorrect

c. The given statement would case Cartesian or Cross Join

d. The given statement is an Equijoin

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 14/20
7/31/2019 Finals

Question 39 Supposed that table: Workers and Employees is consists of the


Answer saved following values.
Marked out of What will be the output if the user uses this PL/SQL.
1.00
 UPDATE WORKERS

SET DEPARTMENT = (SELECT DEPARTMENT FROM EMPLOYEES WHERE


 DEPARTMENT =’HR’);

Select one:
a. All Workers department will be set to HRD

b. All Workers department will be set to NULL

c. The department of employee with ID number 105 will be


set to NULL

d. There will be no changes on the department of employee


ID number 105.

Clear my choice

Question 40 It is formed when a join condition is omitted.


Answer saved

Marked out of Select one:


1.00
a. Cross Join

b. Cartesian Product

c. Self-Join

d. Natural Join

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 15/20
7/31/2019 Finals

Question 41 Supposed that table: Workers and Employees is consists of the


Answer saved following values. What will be the output if the user uses this
Marked out of PL/SQL.
1.00
 SELECT ID, LASTNAME, DEPARTMENT
FROM WORKERS
 WHERE ID > (SELECT ID FROM EMPLOYEES WHERE STATUS = ‘Probi’);


 

Select one:
a. This will retrieve the record of Subion, Mortos and
Santiago

b. No rows or 0 rows are Selected

c. This will retrieve the record of Mortos and Santiago

d. 0 rows are deleted in Workers table

Clear my choice

Question 42 Which of the following joins are mutually exclusive.


Answer saved

Marked out of Select one:


1.00
a. Natural Join and Using clause

b. Inner join and Outer Join

c. Left and Right Outer join

d. IN and Using clause

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 16/20
7/31/2019 Finals

Question 43

Answer saved

Marked out of
1.00

 In the given complex view example what will be the possible


output if this code is run?
 CREATE OR REPLACE VIEW DEPT_EMP
AS (SELECT EMPLOYEE_ID, LASTNAME, DEPARTMENT_NAME
 FROM EMPLOYEES JOIN DEPARTMENT)

 Select one:
a. Cause an error because the JOIN condition is omitted.

b. It will successfully create the view that join 1 table to
another table.

c. The OR REPLACE on the code should be omitted.

d. Missing with CHECK OPTION

Clear my choice

Question 44 Supposed that table: Workers and Employees is consists of the


Answer saved following values.
Marked out of
1.00

What will be the output if the user uses this PL/SQL.


UPDATE EMPLOYEES

SET LASTNAME = (SELECT LASTNAME FROM WORKERS WHERE


LASTNAME=’Soriano’)
WHERE ID=105;

Select one:
a. The values of Employee with ID number 105 will be deleted

b. All Workers lastname will be set to NULL

c. The lastname of Cruz from Employees table will be set to


NULL

d. The lastname of Cruz from Employees table will be set to


Soriano

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 17/20
7/31/2019 Finals

Question 45 Which of the following is the correct example of multiple row


Answer saved subquery?
Marked out of
1.00 Select one:

a. SELECT EMPLOYEE_ID, SALARY
FROM EMPLOYEES

HAVING MIN(SALARY);

 b. SELECT EMPLOYEE_ID, MIN(SALARY)


FROM EMPLOYEES
 WHERE SALARY =(SELECT MIN(SALARY) FROM EMPLOYEES;

c. SELECT EMPLOYEE_ID, SALARY


 FROM EMPLOYEES
WHERE SALARY =(SELECT MIN(SALARY) FROM EMPLOYEES;
 d. SELECT EMPLOYEE_ID, MIN(SALARY)
FROM EMPLOYEES;

Clear my choice

Question 46 This is a type of attribute that is made of more than one simple
Answer saved attribute.
Marked out of
1.00 Select one:
a. Natural Attribute

b. Derived Attribute

c. Simple Attribute

d. Composite Attribute

Clear my choice

Question 47 Supposed that table: Workers and Employees is consists of the


Answer saved following values.
Marked out of
1.00

What will be the output if the user uses this PL/SQL.


SELECT ID, LASTNAME, DEPARTMENT
FROM WORKERS
WHERE ID > (SELECT ID FROM EMPLOYEES WHERE STATUS = ‘Probi’);

Select one:
a. This will retrieve the record of Mortos and Santiago

b. No rows or 0 rows are Selected

c. 0 rows are delete in Workers table

d. This will retrieve the record of Subio, Mortos and Santiago

Clear my choice

https://blended.amauonline.com/mod/quiz/attempt.php 18/20
7/31/2019 Finals

Question 48 This is used to quality ambiguous column when joining two or


Answer saved more tables.
Marked out of
1.00 Select one:

a. Column Alias

 b. Column Prefixes

c. Table Prefixes

d. Table Alias

 Clear my choice


Question 49 Which of the following is the correct query that will create a
 Answer saved report that will display the following: STREET_ADDRESS, CITY,
Marked out of DEPARTMENT_NAME and LOATION_ID? Use using clause to get the
 1.00 data from two tables.

 Select one:
a. SELECT STREET_ADDRESS, CITY, DEPARTMENT_NAME,
LOCATION_ID
FROM DEPARTMENTS
JOIN LOCATIONS
USING (LOCATIONS);

b. SELECT STREET_ADDRESS, CITY, DEPARTMENT_NAME,


LOCATION_ID
FROM DEPARTMENTS
JOIN LOCATIONS
NATURAL JOIN (LOCATION_ID);

c. SELECT STREET_ADDRESS, CITY, DEPARTMENT_NAME,


LOCATION_ID
FROM DEPARTMENTS
JOIN LOCATIONS
USING (LOCATION_ID);

d. SELECT STREET_ADDRESS, CITY, DEPARTMENT_NAME,


LOCATION_ID
FROM DEPARTMENTS
JOIN LOCATIONS
WHERE USING (LOCATION_ID);

Clear my choice

Question 50 SELECT employees.employee_id,


Answer saved employees.lastname,employees.department_id,
Marked out of departments.department_id,departments.location_id
1.00 FROM employees LEFT JOIN departments
ON( employees.department_id = departments.department_id);

Select one:
a. The given statement would cause Cartesian or Cross Join

b. The given statement is an Equijoin

c. The given statement is not a valid join condition or is


incorrect

d. The given statement is Outer Join

Clear my choice

Stay in touch
AMA EDUCATION SYSTEM
https://blended.amauonline.com/mod/quiz/attempt.php 19/20
7/31/2019 Finals

 https://blended.amauonline.com/helpdesk

https://blended.amauonline.com/mod/quiz/attempt.php 20/20

Potrebbero piacerti anche