Wa0011.
Wa0011.
Wa0011.
Question #1 Topic 1
FROM customers -
WHERE country_id = 10 -
UNION -
SELECT cust_id CUST_NO, cust_last_name
FROM customers -
WHERE country_id = 30 -
Identify three ORDER BY clauses either one of which can complete the query.
B. ORDER BY 2, cust_id
C. ORDER BY CUST_NO
D. ORDER BY 2, 1
E. ORDER BY "CUST_NO"
Question #2 Topic 1
Which three statements are true regarding the WHERE and HAVING clauses in a SQL statement? (Choose three.)
C. The HAVING clause conditions can use aliases for the columns.
D. The WHERE clause is used to exclude rows before the grouping of data.
E. The HAVING clause is used to exclude one or more aggregated results after grouping data.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 1/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Question #3 Topic 1
A. The CREATE TABLE AS SELECT statement can be used to upload data into a normal table in the database from an external table.
B. The data and metadata for an external table are stored outside the database.
D. ORACLE_LOADER and ORACLE_DATAPUMP have exactly the same functionality when used with an external table.
Question #4 Topic 1
Which two statements are true about Data Manipulation Language (DML) statements?
A. An INSERT INTO...VALUES.. statement can add multiple rows per execution to a table.
B. An UPDATE... SET... statement can modify multiple rows based on multiple conditions on a table.
C. A DELETE FROM..... statement can remove rows based on only a single condition on a table.
D. An INSERT INTO... VALUES..... statement can add a single row based on multiple conditions on a table.
E. A DELETE FROM..... statement can remove multiple rows based on multiple conditions on a table.
F. An UPDATE....SET.... statement can modify multiple rows based on only a single condition on a table.
Question #5 Topic 1
D. The REVOKE command can be used to remove privileges but not roles from other users.
E. Roles are named groups of related privileges that can be granted to users or other roles.
Question #6 Topic 1
D. You can have more than one column in a table as part of a primary key.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 2/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Question #7 Topic 1
Which statement is true regarding the evaluation of rows returned by the subquery in the INSERT statement?
A. They are evaluated by all the three WHEN clauses regardless of the results of the evaluation of any other WHEN clause.
B. They are evaluated by the first WHEN clause. If the condition is true, then the row would be evaluated by the subsequent WHEN clauses.
C. They are evaluated by the first WHEN clause. If the condition is false, then the row would be evaluated by the subsequent WHEN clauses.
D. The insert statement would give an error because the ELSE clause is not present for support in case none of WHEN clauses are true.
Question #8 Topic 1
You want to display details of all members who reside in states starting with the letter A followed by exactly one character.
Which SQL statement must you execute?
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 3/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Question #9 Topic 1
You want to display 5 percent of the rows from the SALES table for products with the lowest AMOUNT_SOLD and also want to include the rows
that have the same even if this causes the output to exceed 5 percent of the rows.
AMOUNT_SOLD -
Which query will provide the required result?
A. SELECT prod_id, cust_id, amount_sold FROM sales ORDER BY amount_sold FETCH FIRST 5 PERCENT ROWS WITH TIES;
B. SELECT prod_id, cust_id, amount_sold FROM sales ORDER BY amount_sold FETCH FIRST 5 PERCENT ROWS ONLY WITH TIES;
C. SELECT prod_id, cust_id, amount_sold FROM sales ORDER BY amount_sold FETCH FIRST 5 PERCENT ROWS WITH TIES ONLY;
D. SELECT prod_id, cust_id, amount_sold FROM sales ORDER BY amount_sold FETCH FIRST 5 PERCENT ROWS ONLY;
A. It fails because the alias name specified after the column names is invalid.
B. It fails because the space specified in single quotation marks after the first two column names is invalid.
C. It executes successfully and displays the column details in a single column with only the alias column heading.
D. It executes successfully and displays the column details in three separate columns and replaces only the last column heading with the
alias.
D. All views and synonyms on the table remain but they are invalidated.
E. All data in the table is deleted but the table structure remains.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 4/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
FROM employees -
WHERE hire_date > '&hiredate'
AND manager_id > &mgr_id;
For which substitution variables are you prompted for the input?
C. only hiredate'
D. only 'mgr_id'
View the Exhibit and examine the structure of ORDERS and ORDER_ITEMS tables. is the primary key in the ORDERS table. It is also the foreign
key in the ORDER_ITEMS table wherein it is created with the ON DELETE CASCADE option.
ORDER_ID -
Which DELETE statement would execute successfully?
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 5/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. SELECT NVL (TO CHAR(cust_credit_limit * .15), 'Not Available') "NEW CREDIT" FROM customers;
B. SELECT TO_CHAR (NVL(cust_credit_limit * .15), 'Not Available') "NEW CREDIT" FROM customers;
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 6/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit and examine the structures of the EMPLOYEES and DEPARTMENTS tables.
What is outcome?
A. It generates an error because multiple columns (SALARY, COMMISSION) cannot be specified together in an UPDATE statement.
B. It generates an error because a subquery cannot have a join condition in a UPDATE statement.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 7/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. Performance would improve in query 2 only if there are null values in the CUST_CREDIT_LIMIT column.
A. The ERD must have a 1:M relationship between the STUDENTS and PROJECTS entities.
B. The ERD must have a M:M relationship between the STUDENTS and PROJECTS entities that must be resolved into 1:M relationships.
C. STUDENT_ID must be the primary key in the STUDENTS entity and foreign key in the PROJECTS entity.
D. PROJECT_ID must be the primary key in the PROJECTS entity and foreign key in the STUDENTS entity.
E. An associative table must be created with a composite key of STUDENT_ID and PROJECT_ID, which is the foreign key linked to the
STUDENTS and entities. PROJECTS
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 8/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You have the requirement to display PRODUCT_NAME from the table where the CATEGORY_ID column has values 12 or 13, and the SUPPLIER_ID
column has the value 102088. You executed the following SQL statement:
SELECT product_name -
FROM product_information -
WHERE (category_id = 12 AND category_id = 13) AND supplier_id = 102088;
Which statement is true regarding the execution of the query?
A. It would not execute because the same column has been used in both sides of the AND logical operator to form the condition.
B. It would not execute because the entire WHERE clause condition is not enclosed within the parentheses.
C. It would execute and the output would display the desired result.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 9/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements are true regarding the EXISTS operator used in the correlated subqueries? (Choose two.)
A. The outer query stops evaluating the result set of the inner query when the first value is found.
B. It is used to test whether the values retrieved by the inner query exist in the result of the outer query.
C. It is used to test whether the values retrieved by the outer query exist in the result set of the inner query.
D. The outer query continues evaluating the result set of the inner query until all the values in the result set are processed.
View the exhibit and examine the structure of the STORES table.
You must display the NAME of stores along with the ADDRESS, START_DATE, PROPERTY_PRICE, and the projected property price, which is
115% of property price.
The stores displayed must have START_DATE in the range of 36 months starting from 01-Jan-2000 and above.
Which SQL statement would get the desired output?
A. SELECT name, concat (address| | ','| |city| |', ', country) AS full_address, start_date, property_price, property_price*115/100 FROM stores
WHERE MONTHS_BETWEEN (start_date, '01-JAN-2000') <=36;
B. SELECT name, concat (address| | ','| |city| |', ', country) AS full_address, start_date, property_price, property_price*115/100 FROM stores
WHERE TO_NUMBER(start_date-TO_DATE('01-JAN-2000','DD-MON-RRRR')) <=36;
C. SELECT name, address||', '||city||', '||country AS full_address, start_date, property_price, property_price*115/100 FROM stores WHERE
MONTHS_BETWEEN(start_date,TO_DATE('01-JAN-2000','DD-MON-RRRR')) <=36;
D. SELECT name, concat (address||','| |city| |', ', country) AS full_address, start_date, property_price, property_price*115/100 FROM stores
WHERE MONTHS_BETWEEN (start_date, TO_DATE('01-JAN-2000','DD-MON-RRRR')) <=36;
A. The execution fails unless the numeral 3 in the ORDER BY clause is replaced by a column name.
B. Rows are displayed in the order that they are stored in the table only for the three rows with the lowest values in the key column.
C. Rows are displayed in the order that they are stored in the table only for the first three rows.
D. Rows are displayed sorted in ascending order of the values in the third column in the table.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 10/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
B. When the BOOKS table is dropped, all the rows in the BOOK_TRANSACTIONS table are deleted but the table structure is retained.
C. When a row in the BOOKS table is deleted, the rows in the BOOK_TRANSACTIONS table whose BOOK_ID matches that of the deleted row
in the BOOKS table are also deleted.
D. When a value in the BOOKS.BOOK_ID column is deleted, the corresponding value is updated in the BOOKS_TRANSACTIONS.BOOK_ID
column.
View the exhibit and examine the structure of the EMPLOYEES table.
You want to display all employees and their managers having 100 as the MANAGER_ID. You want the output in two columns: the first column
would have the of the managers and the second column would have LAST_NAME of the employees.
LAST_NAME -
Which SQL statement would you execute?
A. SELECT m.last_name "Manager", e.last_name "Employee" FROM employees m JOIN employees e ON m.employee_id = e.manager_id
WHERE m.manager_id = 100;
B. SELECT m.last_name "Manager", e.last_name "Employee" FROM employees m JOIN employees e ON m.employee_id = e.manager_id
WHERE e.manager_id = 100;
C. SELECT m.last_name "Manager", e.last_name "Employee" FROM employees m JOIN employees e ON e.employee_id = m.manager_id
WHERE m.manager_id = 100;
D. SELECT m.last_name "Manager", e.last_name "Employee" FROM employees m JOIN employees e WHERE m.employee_id = e.manager_id
AND e.manager_id = 100
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 11/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
E. They can contain group functions and GROUP BY and HAVING clauses.
F. They can contain group functions and the GROUP BY clause, but not the HAVING clause.
A. SELECT e.last_name, m.manager_id FROM employees e RIGHT OUTER JOIN employees m on (e.manager_id = m.employee_id) AND
e.employee_id = 123;
B. SELECT e.last_name, m.manager_id FROM employees e LEFT OUTER JOIN employees m on (e.employee_id = m.manager_id) WHERE
e.employee_id = 123;
C. SELECT e.last_name, e.manager_id FROM employees e RIGHT OUTER JOIN employees m on (e.employee_id = m.employee_id) WHERE
e.employee_id = 123;
D. SELECT m.last_name, e.manager_id FROM employees e LEFT OUTER JOIN employees m on (e.manager_id = m.manager_id) WHERE
e.employee_id = 123;
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 12/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which normal form is a table in if it has no multi-valued attributes and no partial dependencies?
Sales data of a company is stored in two tables, SALES1 and SALES2, with some data being duplicated across the tables. You want to display
the results from the table, which are not present in the SALES2 table.
SALES1 -
A. INTERSECT
B. UNION
C. PLUS
D. MINUS
E. SUBTRACT
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 13/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. After executing the ALTER TABLE command, you can add a new column called ORDER_DATE to the ORDERS table.
B. The ORDER_DATE column must be empty for the ALTER TABLE command to execute successfully.
C. ROLLBACK can be used to get back the ORDER_DATE column in the ORDERS table.
Evaluate the following SQL statements that are issued in the given order:
A. It would remain disabled and can be enabled only by dropping the foreign key constraint and recreating it.
B. It would remain disabled and has to be enabled manually using the ALTER TABLE command.
Which three statements are true regarding the data types? (Choose three.)
A. The minimum column width that can be specified for a VARCHAR2 data type column is one.
C. A TIMESTAMP data type column stores only time values with fractional seconds.
D. The BLOB data type column is used to store binary data in an operating system file.
E. The value for a CHAR data type column is blank-padded to the maximum defined column width.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 14/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. Multiple columns or expressions can be compared between the main query and subquery.
C. Main query and subquery can get data from different tables.
E. Main query and subquery must get data from the same tables.
F. Only one column or expression can be compared between the main query and subquery.
Which statement is true regarding the default behavior of the ORDER BY clause?
C. Only those columns that are specified in the SELECT list can be used in the ORDER BY clause.
D. Numeric values are displayed from the maximum to the minimum value if they have decimal positions.
Which query can be used to display the last names and city names only for members from the states MO and MI?
A. SELECT last_name, city FROM members WHERE state ='MO' AND state ='MI';
D. SELECT DISTINCT last_name, city FROM members WHERE state ='MO' OR state ='MI';
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 15/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which statement is true about an inner join specified in a query's WHERE clause?
D. It must have primary-key and foreign-key constraints defined on the join columns.
Which task can be performed by using a single Data Manipulation Language (DML) statement?
B. adding a column with a default value while inserting a row into a table
C. removing all data only from a single column on which a unique constraint is defined
D. removing all data only from a single column on which a primary key constraint is defined
You want to display the member IDs, due date, and late fee as $2 for all transactions.
Which SQL statement must you execute?
B. SELECT member_id 'MEMBER ID', due_date 'DUE DATE', '$2 AS LATE FEE' FROM BOOKS_TRANSACTIONS;
C. SELECT member_id AS "MEMBER ID", due_date AS "DUE DATE", '$2' AS "LATE FEE" FROM BOOKS_TRANSACTIONS;
D. SELECT member_id AS "MEMBER ID", due_date AS "DUE DATE", $2 AS "LATE FEE" FROM BOOKS_TRANSACTIONS;
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 16/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit and examine the data in ORDERS_MASTER and MONTHLY_ORDERS tables.
MERGE_INTO orders_master o -
USING monthly_orders m -
ON (o.order_id = m.order_id)
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 17/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
FROM product_information -
WHERE product_status = 'obsolete';
You received the following error while executing the above query:
ERROR -
ORA-01756: quoted string not properly terminated
What would you do to execute the query successfully?
A. Remove the single quotation marks enclosing the character literal string in the SELECT clause
B. Use the escape character to negate the single quotation mark within the literal character string in the SELECT clause
C. Enclose the character literal string in the SELECT clause within double quotation marks
D. Use the Oracle (q) operator and delimiter to allow the use of a single quotation mark within the literal character string in the SELECT
clause
The ORDERS table contains data and all orders have been assigned a customer ID. Which statement would add a NOT NULL constraint to the
CUSTOMER_ID column?
C. ALTER TABLE orders MODIFY customer_id CONSTRAINT orders_cust_nn NOT NULL (customer_id);
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 18/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which three statements are true about the ALTER TABLE....DROP COLUMN.... command?
D. The column in a composite PRIMARY KEY with the CASCADE option can be dropped.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 19/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit and examine the description of the PRODUCT_INFORMATION table.
Which SQL statement would retrieve from the table the number of products having LIST_PRICE as NULL?
Which three tasks can be performed using SQL functions built into Oracle Database?
D. combining more than two columns or expressions into a single column in the output
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 20/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
The user SCOTT who is the owner of ORDERS and ORDER_ITEMS tables issues this GRANT command:
GRANT ALL -
ON orders, order_items -
TO PUBLIC;
What must be done to fix the statement?
D. Separate GRANT statements are required for the ORDERS and ORDER_ITEMS tables.
You are designing the structure of a table in which two columns have the specifications:
"" must be able to contain a maximum of 12 alphanumeric characters and must uniquely identify the row
COMPONENT_ID -
"" contains Century, Year, Month, Day, Hour, Minute, Second to the maximum precision and is used for calculations and comparisons
EXECUTION_DATETIME -
between components.
Which two options define the data types that satisfy these requirements most efficiently? (Choose two.)
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 21/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You want to display the date for the first Monday of the next month and issue the following command:
E. In generates an error because fm and double quotation marks should not be used in the format string.
Which two statements are true regarding the GROUP BY clause in a SQL statement? (Choose two.)
B. Using the WHERE clause after the GROUP BY clause excludes the rows after creating groups.
C. The GROUP BY clause is mandatory if you are using an aggregate function in the SELECT clause.
D. Using the WHERE clause before the GROUP BY clause excludes the rows before creating groups.
E. If the SELECT clause has an aggregate function, then those individual columns without an aggregate function in the SELECT clause
should be included in the GROUP BY
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 22/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You want to generate a list of all department IDs along with any course IDs that may have been assigned to them.
Which SQL statement must you use?
A. SELECT d.department_id, c.course_id FROM department_details d RIGHT OUTER JOIN course_details c ON (d.department_id=c.
department_id);
B. SELECT d.department_id, c.course_id FROM department_details d LEFT OUTER JOIN course_details c ON (d.department_id=c.
department_id);
C. SELECT d.department_id, c.course_id FROM course_details c LEFT OUTER JOIN department_details d ON (c.department_id=d.
department_id);
D. SELECT d.department_id, c.course_id FROM department_details d RIGHT OUTER JOIN course_details c ON (c.department_id=d.
department_id);
Which two tasks can be performed by using Oracle SQL statements? (Choose two.)
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 23/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit for the structure of the STUDENT and FACULTY tables.
You need to display the faculty name followed by the number of students handled by the faculty at the base location.
Examine the following two SQL statements:
Statement 1 -
SQL>SELECT faculty_name, COUNT(student_id)
Statement 2 -
SQL>SELECT faculty_name, COUNT(student_id)
FROM student NATURAL JOIN faculty
GROUP BY faculty_name;
Which statement is true regarding the outcome?
D. Both statements 1 and 2 execute successfully and give the same required result.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 24/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit and examine the structure of ORDERS and CUSTOMERS tables.
Which INSERT statement should be used to add a row into the ORDERS table for the customer whose CUST_LAST_NAME is Roberts and
CREDIT_LIMIT is
? Assume there exists only one row with CUST_LAST_NAME as Roberts and CREDIT_LIMIT as 600.
600
A. INSERT INTO (SELECT o.order_id, o.order_date, o.order_mode, c.customer_id, o.order_total FROM orders o, customers c WHERE
o.customer_id = c.customer_id AND c.cust_last_name='Roberts' AND c.credit_limit=600) VALUES (1,'10-mar-2007', 'direct', (SELECT
customer_id FROM customers WHERE cust_last_name='Roberts' AND credit_limit=600), 1000);
B. INSERT INTO orders (order_id, order_date, order_mode, (SELECT customer_id FROM customers WHERE cust_last_name='Roberts' AND
credit_limit=600), order_total) VALUES (1,'10-mar-2007', 'direct', &customer_id, 1000);
C. INSERT INTO orders VALUES (1,'10-mar-2007', 'direct', (SELECT customer_id FROM customers WHERE cust_last_name='Roberts' AND
credit_limit=600), 1000);
D. INSERT INTO orders (order_id, order_date, order_mode, (SELECT customer_id FROM customers WHERE cust_last_name='Roberts' AND
credit_limit=600), order_total) VALUES (1,'10-mar-2007', 'direct', &&customer_id, 1000);
A. A non-deferrable PRIMARY KEY or UNIQUE KEY constraint in a table automatically attempts to create a unique index.
B. Indexes should be created on columns that are frequently referenced as part of any expression.
D. For each DML operation performed on a table, the corresponding indexes are automatically updated if required.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 25/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit and examine the description of the DEPARTMENTS and EMPLOYEES tables.
You wrote this SQL statement to retrieve EMPLOYEE_ID, FIRST_NAME, and DEPARTMENT NAME, for all employees:
SELECT employee_id, first_name, department_name
FROM employees -
NATURAL JOIN departments;
The desired output is not obtained after executing the above SQL statement. What could be the reason for this?
A. The table prefix is missing for the column names in the SELECT clause.
C. The DEPARTMENTS table is not used before the EMPLOYEES table in the FROM clause.
D. The EMPLOYEES and DEPARTMENTS tables have more than one column with the same column name and data type.
Which two statements are true about sequences created in a single instance Oracle database? (Choose two.)
A. When the MAXVALUE limit for a sequence is reached, it can be increased by using the ALTER SEQUENCE statement. > would remove a
sequence from the database.
C. The numbers generated by an explicitly defined sequence can only be used to insert data in one table.
D. CURRVAL is used to refer to the most recent sequence number that has been generated for a particular sequence.
E. When a database instance shuts down abnormally, sequence numbers that have been cached but not used are available again when the
instance is restarted.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 26/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit and examine the structure of the CUSTOMERS table.
Which two tasks would require subqueries or joins to be executed in a single statement?
A. finding the number of customers, in each city, whose credit limit is more than the average credit limit of all the customers
B. finding the average credit limit of male customers residing in 'Tokyo' or 'Sydney'
C. listing of customers who do not have a credit limit and were born before 1980
D. finding the number of customers, in each city, whose marital status is 'married'.
E. listing of those customers, whose credit limit is the same as the credit limit of customers residing in the city 'Tokyo'.
A. A set of Data Manipulation Language (DML) statements executed in a sequence ending with a SAVEPOINT forms a single transaction.
B. Each Data Definition Language (DDL) statement executed forms a single transaction.
C. A set of DDL statements executed in a sequence ending with a COMMIT forms a single transaction.
D. A combination of DDL and DML statements executed in a sequence ending with a COMMIT forms a single transaction.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 27/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit and examine the structure in ORDERS and ORDER_ITEMS tables.
You need to create a view that displays the ORDER_ID, ORDER_DATE, and the total number of items in each order.
Which CREATE VIEW statement would create the view successfully?
A. CREATE OR REPLACE VIEW ord_vu AS SELECT o.order_id, o.order_date, COUNT (i.line_item_id) FROM orders o JOIN order_items i ON
(o.order_id = i.order_id) GROUP BY o.order_id, o.order_date;
B. CREATE OR REPLACE VIEW ord_vu (order_id, order_date) AS SELECT o.order_id, o.order_date, COUNT (i.line_item_id) "NO OF ITEMS"
FROM orders o JOIN order_items i ON (o.order_id = i.order_id) GROUP BY o.order_id, o.order_date;
C. CREATE OR REPLACE VIEW ord_vu AS SELECT o.order_id, o.order_date, COUNT (i.line_item_id) "NO OF ITEMS" FROM orders o JOIN
order_items i ON (o.order_id = i.order_id) GROUP BY o.order_id, o.order_date;
D. CREATE OR REPLACE VIEW ord_vu AS SELECT o.order_id, o.order_date, COUNT (i.line_item_id) || "NO OF ITEMS" FROM orders o JOIN
order_items i ON (o.order_id = i.order_id) GROUP BY o.order_id, o.order_date WHITH CHECK OPTION;
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 28/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which statement is true about an inner join specified in the WHERE clause of a query?
A. It must have primary-key and foreign-key constraints defined on the columns used in the join condition.
B. It requires the column names to be the same in all tables used for the join conditions.
D. The number of columns and data types must be identical for all SELECT statements in the query.
FROM sales -
ORDER BY amount_sold -
FETCH FIRST 5 PERCENT ROWS ONLY;
What is the output of this query?
B. It displays the first 5 percent of the rows from the SALES table.
D. It results in an error because the ORDER BY clause should be the last clause.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 29/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
The first DROP operation is performed on PRODUCTS table using this command:
DROP TABLE products PURGE;
Then a FLASHBACK operation is performed using this command:
FLASHBACK TABLE products TO BEFORE DROP;
Which is true about the result of the FLASHBACK command?
C. It recovers the table structure and data but not the related indexes.
D. It is not possible to recover the table structure, data, or the related indexes.
These are the steps for a correlated subquery, listed in random order:
1. The WHERE clause of the outer query is evaluated.
2. A candidate row is fetched from the table specified in the outer query.
3. This is repeated for the subsequent rows of the table, until all the rows are processed.
4. Rows are returned by the inner query, after being evaluated with the value from the candidate row in the outer query.
Which is the correct sequence in which the Oracle server evaluates a correlated subquery?
A. 2, 1, 4, 3
B. 4, 1, 2, 3
C. 4, 2, 1, 3
D. 2, 4, 1, 3
A. 150
B. 200
C. 160
D. 16
E. 100
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 30/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
CUST_NAME -
-------------------
Renske Ladwig -
Jason Mallin -
Samuel McCain -
Allan MCEwen -
Irene Mikkilineni -
Julia Nayer -
You need to display customers' second names where the second name starts with "Mc" or "MC".
Which query gives the required output?
A. SELECT SUBSTR(cust_name, INSTR (cust_name, ' ')+1) FROM customers WHERE SUBSTR(cust_name, INSTR (cust_name, ' ')+1) LIKE
INITCAP ('MC%');
B. SELECT SUBSTR(cust_name, INSTR (cust_name, ' ')+1) FROM customers WHERE INITCAP(SUBSTR(cust_name, INSTR (cust_name, ' ')+1))
= 'Mc';
C. SELECT SUBSTR(cust_name, INSTR (cust_name, ' ')+1) FROM customers WHERE INITCAP(SUBSTR(cust_name, INSTR (cust_name, ' ')+1))
LIKE 'Mc%';
D. SELECT SUBSTR(cust_name, INSTR (cust_name, ' ')+1) FROM customers WHERE INITCAP(SUBSTR(cust_name, INSTR (cust_name, ' ')+1))
= INITCAP ('MC%');
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 31/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit and examine the structure of the SALES, CUSTOMERS, PRODUCTS and TIMES tables.
The PROD_ID column is the foreign key in the SALES table, which references the PRODUCTS table.
Similarly, the CUST_ID and TIME_ID columns are also foreign keys in the SALES table referencing the CUSTOMERS and TIMES tables,
respectively.
Evaluate the following CREATE TABLE command:
CREATE TABLE new_sales (prod_id, cust_id, order_date DEFAULT SYSDATE)
AS -
SELECT prod_id, cust_id, time_id
FROM sales;
Which statement is true regarding the above command?
A. The NEW_SALES table would get created and all the NOT NULL constraints defined on the specified columns would be passed to the new
table.
B. The NEW_SALES table would not get created because the DEFAULT value cannot be specified in the column definition.
C. The NEW_SALES table would not get created because the column names in the CREATE TABLE command and the SELECT clause do not
match.
D. The NEW_SALES table would get created and all the FOREIGN KEY constraints defined on the specified columns would be passed to the
new table.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 32/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements are true regarding the USING and ON clauses in table joins?
A. Both USING and ON clauses can be used for equijoins and nonequijoins.
B. A maximum of one pair of columns can be joined between two tables using the ON clause.
C. The ON clause can be used to join tables on columns that have different names but compatible data types.
D. The WHERE clause can be used to apply additional conditions in SELECT statements containing the ON or the USING clause.
Which three statements are true regarding group functions? (Choose three.)
C. They can be used only with a SQL statement that has the GROUP BY clause.
D. They can be used on only one column in the SELECT clause of a SQL statement.
E. They can be used along with the single-row function in the SELECT clause of a SQL statement.
B. The data dictionary views consist of joins of dictionary base tables and user-defined tables.
C. The usernames of all the users including database administrators are stored in the data dictionary.
D. The USER_CONS_COLUMNS view should be queried to find the names of columns to which constraints apply.
E. Both USER_OBJECTS and CAT views provide the same information about all objects that are owned by the user.
F. Views with the same name but different prefixes, such as DBA, ALL and USER, reference the same base tables from the data dictionary.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 33/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibits and examine the structures of the COSTS and PROMOTIONS tables.
B. It displays prod IDs in the promos with the lowest cost in the same time interval.
C. It displays prod IDs in the promos with the highest cost in the same time interval.
D. It displays prod IDs in the promos which cost less than the highest cost in the same time interval.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 34/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit and examine the descriptions of the DEPT and LOCATIONS tables.
You want to update the CITY column of the DEPT table for all the rows with the corresponding value in the CITY column of the LOCATIONS table
for each department.
Which SQL statement would you execute to accomplish the task?
A. UPDATE dept d SET city = ALL (SELECT city FROM locations l WHERE d.location_id = l.location_id);
B. UPDATE dept d SET city = (SELECT city FROM locations l) WHERE d.location_id = l.location_id;
D. UPDATE dept d SET city = (SELECT city FROM locations l WHERE d.location_id = l.location_id);
A. The execution fails unless the numeral 3 in the ORDER BY clause is replaced by a column name.
B. All table rows are displayed sorted in ascending order of the values in the third column.
C. The first three rows in the table are displayed in the order that they are stored.
D. Only the three rows with the lowest values in the key column are displayed in the order that they are stored.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 35/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. DML automatically disables foreign ley constraints when modifying primary key values in the parent table.
D. DML disables foreign key constraints when deleting primary key values in the parent table, only when the ON DELETE CASCADE option is
set for the foreign key constraint.
View the exhibit and examine the structure of the PROMOTIONS table.
You have to generate a report that displays the promo name and start date for all promos that started after the last promo in the "˜INTERNET'
category.
Which query would give you the required output?
A. SELECT promo_name, promo_begin_date FROM promotions WHERE promo_begin_date> ALL (SELECT MAX (promo_begin_date) FROM
promotions) AND promo_category= "˜INTERNET';
B. SELECT promo_name, promo_begin_date FROM promotions WHERE promo_begin_date IN (SELECT promo_begin_date FROM promotions
WHERE promo_category= "˜INTERNET');
C. SELECT promo_name, promo_begin_date FROM promotions WHERE promo_begin_date > ALL (SELECT promo_begin_date FROM
promotions WHERE promo_category = "˜INTERNET');
D. SELECT promo_name, promo_begin_date FROM promotions WHERE promo_begin_date> ANY (SELECT promo_begin_date FROM
promotions WHERE promo_category= "˜INTERNET');
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 36/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the ORDER_ITEMS table.
FROM order_items -
WHERE unit_price =
(SELECT MAX(unit_price)
FROM order_items -
GROUP BY order_id);
You want to display the PRODUCT_ID of the product that has the highest UNIT_PRICE per ORDER_ID. What correction should be made in the
above SQL statement to achieve this?
A. Remove the GROUP BY clause from the subquery and place it in the main query
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 37/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
B. It would give an error because the USING INDEX clause cannot be used on a composite primary.
C. It would execute successfully and two indexes ORD_ITM_IDX and ORD_ITM_ID_PK would be created.
D. It would give an error because the USING INDEX clause is not permitted in the CREATE TABLE command.
Using the CUSTOMERS table, you need to generate a report that shows 50% of each credit amount in each income level. The report should NOT
show any repeated credit amounts in each income level.
Which query would give the required result?
A. SELECT cust_income_level || "˜ ' || cust_credit_limit * 0.50 AS "50% Credit Limit" FROM customers.
B. SELECT DISTINCT cust_income_level || "˜ ' || cust_credit_limit * 0.50 AS "50% Credit Limit" FROM customers.
C. SELECT DISTINCT cust_income_level, DISTINCT cust_credit_limit * 0.50 AS "50% Credit Limit" FROM customers.
D. SELECT cust_income_level, DISTINCT cust_credit_limit * 0.50 AS "50% Credit Limit" FROM customers
Which three statements are true regarding the SQL WHERE and HAVING clauses?
B. The HAVING clause conditions can use aliases for the columns.
C. The WHERE and HAVING clauses cannot be used together in a SQL statement.
E. The HAVING clause is used to exclude one or more aggregated results after grouping data.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 38/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You need to display the date 11-oct-2007 in words as "˜Eleventh of October, Two Thousand Seven'.
Which SQL statement would give the required result?
A. SELECT TO_CHAR (TO_DATE ('11-oct-2007'), "˜fmDdthsp "of" Month, Year') FROM DUAL
D. SELECT TO_DATE (TO_CHAR ('11-oct-2007'), "˜fmDdspth "of" Month, Year')) FROM DUAL
You want to generate a report that shows all course IDs irrespective of whether they have corresponding department IDs or not but no
department IDs if they do not have any courses.
Which SQL statement must you use?
A. SELECT course_id, department_id, FROM department_details d RIGHT OUTER JOIN course_details c USING (department_id)
C. SELECT c.course_id, d.department_id FROM course_details c FULL OUTER JOIN department_details d ON (c.department_id=d.
department_id)
D. SELECT c.course_id, d.department_id FROM course_details c FULL OUTER JOIN department_details d ON (c.department_id<>d.
department_id)
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 39/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit and examine the structure of the SALES, CUSTOMERS, PRODUCTS and TIMES tables.
The PROD_ID column is the foreign key in the SALES table referencing the PRODUCTS table.
The CUST_ID and TIME_ID columns are also foreign keys in the SALES table referencing the CUSTOMERS and TIMES tables, respectively.
Examine this command:
CREATE TABLE new_sales (prod_id, cust_id, order_date DEFAULT SYSDATE)
AS -
SELECT prod_id, cust_id, time_id
FROM sales;
Which statement is true?
A. The NEW_SALES table would get created and all the FOREIGN KEY constraints defined on the selected columns from the SALES table
would be created on the corresponding columns in the NEW_SALES table.
B. The NEW_SALES table would not get created because the column names in the CREATE TABLE command and the SELECT clause do not
match.
C. The NEW_SALES table would not get created because the DEFAULT value cannot be specified in the column definition.
D. The NEW_SALES table would get created and all the NOT NULL constraints defined on the selected columns from the SALES table would
be created on the corresponding columns in the NEW_SALES table.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 40/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the ORDERS table. The ORDER_ID column is the PRIMARY KEY in the ORDERS table.
AS -
SELECT order_id.order_date,customer_id
FROM orders;
Which statement is true regarding the above command?
A. The NEW_ODRDERS table would not get created because the DEFAULT value cannot be specified in the column definition.
B. The NEW_ODRDERS table would get created and only the NOT NULL constraint defined on the specified columns would be passed to the
new table.
C. The NEW_ODRDERS table would not get created because the column names in the CREATE TABLE command and the SELECT clause do
not match.
D. The NEW_ODRDERS table would get created and all the constraints defined on the specified columns in the ORDERS table would be
passed to the new table.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 41/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which statement is true regarding the evaluation of rows returned by the subquery in the INSERT statement?
A. Each row is evaluated by the first WHEN clause and if the condition is false then the row would be evaluated by the subsequent when
clauses.
C. Each row is evaluated by the first WHEN clause and if the condition is true, then the row would be evaluated by the subsequent when
clauses.
D. The INSERT statement will return an error because the ELSE clause is missing.
Which two statements are true regarding the SQL GROUP BY clause?
B. Using the WHERE clause after the GROUP BY clause excludes rows after creating groups.
C. The GROUP BY clause is mandatory if you are using an aggregating function in the SELECT clause.
D. Using the WHERE clause before the GROUP BY clause excludes rows before creating groups.
E. If the SELECT clause has an aggregating function, then columns without an aggregating function in the SELECT clause should be
included in the GROUP BY clause.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 42/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. All existing views and synonyms that refer to the table are invalidated but retained.
D. All the table's indexes if any exist, are invalidated but retained.
A. It fails because the NOT NULL and DEFAULT options cannot be combined for the same column.
B. It succeeds and CITY can contain only "˜SEATTLE' or null for all rows.
C. It fails because the condition for the CNAMES constraint is not valid.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 43/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
CREATE_TABLE orders -
(ord_no NUMBER (2) CONSTRAINT ord_pk PRIMARY KEY,
ord_date DATE,
cust_id NUMBER (4) );
C. The CHECK constraint cannot be placed on columns having the DATE data type.
D. ORD_NO and ITEM_NO cannot be used as a composite primary key because ORD_NO is also the FOREIGN KEY.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 44/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the CUSTOMERS table.
Using the CUSTOMERS table, you must generate a report that displays a credit limit increase of 15% for all customers.
Customers with no credit limit should have "Not Available" displayed.
Which SQL statement would produce the required result?
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 45/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Examine these SQL statements that are executed in the given order:
D. It will remain disabled and can be enabled only by dropping the foreign key constraint and re-creating it.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 46/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure in the EMPLOYEES tables.
FROM employees -
WHERE department_id= 50 ORDER BY department_id
UNION -
SELECT employee_id, department_id
FROM employees -
WHERE department_id=90 -
UNION -
SELECT employee_id, department_id
FROM employees -
WHERE department_id=10;
A. The statement would not execute because the positional notation instead of the column name should be used with the ORDER BY clause.
B. The statement would execute successfully and display all the rows in the ascending order of DEPARTMENT_ID.
C. The statement would execute successfully but it will ignore the ORDER BY clause and display the rows in random order.
D. The statement would not execute because the ORDER BY clause should appear only at the end of the SQL statement, that is, in the last
SELECT statement.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 47/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the description for the SALES and CHANNELS tables. (Choose the best answer.)
A. The statement will fail because the subquery in the VALUES clause is not enclosed within single quotation marks.
B. The statement will fail because a subquery cannot be used in a VALUES clause.
C. The statement will execute and a new row will be inserted in the SALES table.
D. The statement will fail because the VALUES clause is not required with the subquery.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 48/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the description of the ORDERS table.
Which two WHERE clause conditions demonstrate the correct usage of conversion functions? (Choose two.)
Which three arithmetic operations can be performed on a column by using a SQL function that is built into Oracle database? (Choose three.)
C. Raising to a power
D. Subtraction
E. Addition
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 49/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the EMPLOYEES and JOB_HISTORY tables.
Examine this query which must select the employee IDs of all the employees who have held the job SA_MAN at any time during their
employment.
SELECT EMPLOYEE_ID -
FROM EMPLOYEES -
WHERE JOB_ID = 'SA_MAN'
-------------------------------------
SELECT EMPLOYEE_ID -
FROM JOB_HISTORY -
WHERE JOB_ID = 'SA_MAN';
Choose two correct SET operators which would cause the query to return the desired result.
A. UNION
B. MINUS
C. INTERSECT
D. UNION ALL
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 50/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You must create a SALES table with these column specifications and data types: (Choose the best answer.)
SALESID: Number -
STOREID: Number -
ITEMID: Number -
QTY: Number, should be set to 1 when no value is specified
SLSDATE: Date, should be set to current date when no value is specified
PAYMENT: Characters up to 30 characters, should be set to CASH when no value is specified
Which statement would create the table?
A. CREATE TABLE sales( salesid NUMBER(4), storeid NUMBER(4), itemid NUMBER(4), qty NUMBER DEFAULT = 1, slsdate DATE DEFAULT
SYSDATE, payment VARCHAR2(30) DEFAULT = "CASH");
B. CREATE TABLE sales( salesid NUMBER(4), storeid NUMBER(4), itemid NUMBER(4), qty NUMBER DEFAULT 1, slsdate DATE DEFAULT
'SYSDATE', payment VARCHAR2(30) DEFAULT CASH);
C. CREATE TABLE sales( salesid NUMBER(4), storeid NUMBER(4), itemid NUMBER(4), qty NUMBER DEFAULT = 1, slsdate DATE DEFAULT
SYSDATE, payment VARCHAR2(30) DEFAULT = "CASH");
D. CREATE TABLE sales( salesid NUMBER(4), storeid NUMBER(4), itemid NUMBER(4), qty NUMBER DEFAULT 1, slsdate DATE DEFAULT
SYSDATE, payment VARCHAR2(30) DEFAULT 'CASH');
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 51/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the details of the PRODUCT_INFORMATION table.
A. A row whose LIST_PRICE column contains value 11235.90 would be displayed as #######.
B. A row whose LIST_PRICE column contains value 1123.90 would be displayed as $1,123.
C. A row whose LIST_PRICE column contains value 1123.90 would be displayed as $1,124.
D. A row whose LIST_PRICE column contains value 11235.90 would be displayed as $1,123.
Which statement is true about SQL query processing in an Oracle database instance? (Choose the best answer.)
A. During parsing, a SQL statement containing literals in the WHERE clause that has been executed by any session and which is cached in
memory, is always reused for the current execution.
B. During execution, the Oracle server may read data from storage if the required data is not already in memory.
C. During row source generation, rows that satisfy the query are retrieved from the database and stored in memory.
D. During optimization, execution plans are formulated based on the statistics gathered by the database instance, and the lowest cost plan
is selected for execution.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 52/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Examine the structure of the ORDERS table: (Choose the best answer.)
You want to find the total value of all the orders for each year and issue this command:
SQL> SELECT TO_CHAR(order_date,'rr'), SUM(order_total) FROM orders
GROUP BY TO_CHAR(order_date, 'yyyy');
Which statement is true regarding the result?
D. It return an error because the datatype conversion in the SELECT list does not match the data type conversion in the GROUP BY clause.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 53/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the ORDER_ITEMS table.
You must select the ORDER_ID of the order that has the highest total value among all the orders in the ORDER_ITEMS table.
Which query would produce the desired result?
A. SELECT order_id FROM order_items GROUP BY order_id HAVING SUM(unit_price*quantity) = (SELECT MAX(SUM(unit_price*quantity))
FROM order_items GROUP BY order_id);
B. SELECT order_id FROM order_items WHERE(unit_price*quantity) = (SELECT MAX(unit_price*quantity) FROM order_items) GROUP BY
order_id;
D. SELECT order_id FROM order_items WHERE (unit_price*quantity) = (SELECT MAX(unit_price*quantity) FROM order_items GROUP BY
order_id)
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 54/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the EMP table which is not partitioned and not an index-organized table. (Choose two.)
A. The FIRST_NAME column can be dropped even if it is part of a composite PRIMARY KEY provided the CASCADE option is added to the
SQL statement.
B. The FIRST_NAME column would be dropped provided at least one column remains in the table.
C. The FIRST_NAME column would be dropped provided it does not contain any data.
D. The drop of the FIRST_NAME column can be rolled back provided the SET UNUSED option is added to the SQL statement.
View the exhibit and examine the structure and data in the INVOICE table.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 55/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements best describe the benefits of using the WITH clause? (Choose two.)
A. It can improve the performance of a large query by storing the result of a query block having the WITH clause in the session's temporary
tablespace.
B. It enables sessions to reuse the same query block in a SELECT statement, if it occurs more than once in a complex query.
C. It enables sessions to store a query block permanently in memory and use it to create complex queries.
C. If a subquery returns NULL, the main query may still return rows.
E. Logical operators, such as AND, OR and NOT, cannot be used in the WHERE clause of a subquery.
Which two statements are true regarding single row functions? (Choose two.)
E. INSTR : can be used to find only the first occurrence of a character in a string.
F. TRIM : can be used to remove all the occurrences of a character from a string.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 56/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the ORDERS table.
You must select ORDER_ID and ORDER_DATE for all orders that were placed after the last order placed by CUSTOMER_ID 101.
Which query would give you the desired result?
A. SELECT order_id, order_date FROM orders WHERE order_date > ANY (SELECT order_date FROM orders WHERE customer_id = 101);
B. SELECT order_id, order_date FROM orders WHERE order_date > ALL (SELECT MAX(order_date) FROM orders ) AND customer_id = 101;
C. SELECT order_id, order_date FROM orders WHERE order_date > ALL (SELECT order_date FROM orders WHERE customer_id = 101);
D. SELECT order_id, order_date FROM orders WHERE order_date > IN (SELECT order_date FROM orders WHERE customer_id = 101);
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 57/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You must display details of all users whose username contains the string 'ch_'. (Choose the best answer.)
Which query generates the required output?
Which three statements are true regarding the usage of the WITH clause in complex correlated subqueries? (Choose three.)
C. If the query block name and the table name are the same, then the table name takes precedence.
D. The query name in the WITH clause is visible to other query blocks in the WITH clause as well as to the main query block
View the Exhibit and examine the data in the PRODUCTS table.
You must display product names from the PRODUCTS table that belong to the 'Software/other' category with minimum prices as either $2000 or
$4000 and with no unit of measure.
You issue this query:
C. It generates an error because the condition specified for PROD_UNIT_OF_MEASURE is not valid.
D. It generates an error because the condition specified for the PROD_CATEGORY column is not valid.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 58/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You must display the maximum and minimum salaries of employees hired 1 year ago.
Which two statements would provide the correct output? (Choose two.)
A. SELECT MIN(Salary) minsal, MAX(salary) maxsal FROM employees WHERE hire_date < SYSDATE-365 GROUP BY MIN(salary),
MAX(salary);
B. SELECT minsal, maxsal FROM (SELECT MIN(salary) minsal, MAX(salary) maxsal FROM employees WHERE hire_date < SYSDATE-365)
GROUP BY maxsal, minsal;
C. SELECT minsal, maxsal FROM (SELECT MIN(salary) minsal, MAX(salary) maxsal FROM employees WHERE hire_date < SYSDATE-365
GROUP BY MIN(salary), MAX(salary));
D. SELECT MIN(Salary), MAX(salary) FROM (SELECT salary FROM employees WHERE hire_date < SYSDATE-365);
E. There is no limit on the number of subquery levels in the WHERE clause of a SELECT statement.
Which two statements are true regarding the execution of the correlated subqueries? (Choose two.)
A. The nested query executes after the outer query returns the row.
B. The nested query executes first and then the outer query executes.
C. The outer query executes only once for the result returned by the inner query.
D. Each row returned by the outer query is evaluated for the results returned by the inner query.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 59/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statement are true regarding table joins available in the Oracle Database server? (Choose two.)
A. You can use the ON clause to specify multiple conditions while joining tables.
B. You can explicitly provide the join condition with a NATURAL JOIN.
C. You can use the JOIN clause to join only two tables.
D. You can use the USING clause to join tables on more than one column.
C. All indexes and constraints defined on the table being dropped are also dropped.
View the exhibit and examine the data in the PROJ_TASK_DETAILS table. (Choose the best answer.)
The PROJ_TASK_DETAILS table stores information about project tasks and the relation between them.
The BASED_ON column indicates dependencies between tasks.
Some tasks do not depend on the completion of other tasks.
You must generate a report listing all task IDs, the task ID of any task upon which it depends and the name of the employee in charge of the
task upon which it depends.
Which query would give the required result?
A. SELECT p.task_id, p.based_on, d.task_in_charge FROM proj_task_details p JOIN proj_task_details d ON (p.task_id = d.task_id);
B. SELECT p.task_id, p.based_on, d.task_in_charge FROM proj_task_details p FULL OUTER JOIN proj_task_details d ON (p.based_on =
d.task_id);
C. SELECT p.task_id, p.based_on, d.task_in_charge FROM proj_task_details p JOIN proj_task_details d ON (p.based_on = d.task_id);
D. SELECT p.task_id, p.based_on, d.task_in_charge FROM proj_task_details p LEFT OUTER JOIN proj_task_details d ON (p.based_on =
d.task_id);
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 60/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the SALES and PRODUCTS tables. (Choose two.)
In the SALES table, PROD_ID is the foreign key referencing PROD_ID in the PRODUCTS table. You must list each product ID and the number of
times it has been sold.
Examine this query which is missing a JOIN operator:
Which two JOIN operations can be used to obtain the required output?
B. JOIN
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 61/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit and examine the description of the EMPLOYEES table. (Choose two.)
FROM employees -
ORDER BY department_id, first_name, salary desc;
Which two statements are true regarding the result? (Choose two.)
A. The values in the SALARY column would be returned in descending order for all employees having the same value in the
DEPARTMENT_ID and FIRST_NAME column.
B. The values in the FIRST_NAME column would be returned in ascending order for all employees having the same value in the
DEPARTMENT_ID column.
C. The values in the SALARY column would be returned in descending order for all employees having the same value in the
DEPARTMENT_ID column.
E. The values in the FIRST_NAME column would be returned in descending order for all employees having the same value in the
DEPARTMENT_ID column.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 62/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements are true about the SALES1 table? (Choose two.)
A. It will not be created because the column-specified names in the SELECT and CREATE TABLE clauses do not match.
B. It will have NOT NULL constraints on the selected columns which had those constraints in the SALES table.
E. It has PRIMARY KEY and UNIQUE constraints on the selected columns which had those constraints in the SALES table.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 63/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Examine this SELECT statement and view the Exhibit to see its output:
FROM user_constraints -
WHERE table_name = 'ORDERS';
Which two statements are true about the output? (Choose two.)
A. The DELETE_RULE column indicates the desired state of related rows in the child table when the corresponding row is deleted from the
parent table.
A. All constraints can be defined at the column level and at the table level.
Which two statements are true regarding working with dates? (Choose two.)
A. The RR date format automatically calculates the century from the SYSDATE function but allows the session user to enter the century.
B. The RR date format automatically calculates the century from the SYSDATE function and does not allow a session user to enter the
century.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 64/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of ORDERS and CUSTOMERS tables. (Choose the best answer.)
A. It would not execute because a subquery cannot be used in the WHERE clause of an UPDATE statement.
B. It would not execute because two tables cannot be referenced in a single UPDATE statement.
C. It would execute and restrict modifications to the columns specified in the SELECT statement.
D. It would not execute because a SELECT statement cannot be used in place of a table name.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 65/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the PRODUCTS table.
You must display the category with the maximum number of items.
You issue this query:
A. It generates an error because = is not valid and should be replaced by the IN operator.
D. It generate an error because the subquery does not have a GROUP BY clause.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 66/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Examine the structure of the MEMBERS table: (Choose the best answer.)
A. It displays all cities in descending order, within which the last names are further sorted in descending order.
C. It fails because a column number and a column alias cannot be used together in the ORDER BY clause.
D. It displays all cities in ascending order, within which the last names are further sorted in descending order.
View and Exhibit and examine the structure and data in the INVOICE table.
Which two statements are true regarding data type conversion in query expressions? (Choose two.)
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 67/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You must display the details of employees who have manager with MANAGER_ID 100, who were hired in the past 6 months and who have
salaries greater than
10000.
Which query would retrieve the required result?
A. SELECT last_name, hire_date, salary FROM employees WHERE salary > 10000 UNION ALL SELECT last_name, hire_date, salary FROM
employees WHERE manager_ID = (SELECT employee_id FROM employees WHERE employee_id = 100) INTERSECT SELECT last_name,
hire_date, salary FROM employees WHERE hire_date > SYSDATE- 180;
B. SELECT last_name, hire_date, salary FROM employees WHERE manager_id = (SELECT employee_id FROM employees WHERE employee_id
= 100) UNION ALL (SELECT last_name, hire_date, salary FROM employees WHERE hire_date > SYSDATE -180 INTERSECT SELECT
last_name, hire_date, salary FROM employees WHERE salary > 10000);
C. SELECT last_name, hire_date, salary FROM employees WHERE manager_id = (SELECT employee_id FROM employees WHERE employee_id
= '100') UNION SELECT last_name, hire_date, salary FROM employees WHERE hire_date > SYSDATE -180 INTERSECT SELECT last_name,
hire_date, salary FROM employees WHERE salary > 10000;
D. (SELECT last_name, hire_date, salary FROM employees WHERE salary > 10000 UNION ALL SELECT last_name, hire_date, salary FROM
employees WHERE manager_ID = (SELECT employee_id FROM employees WHERE employee_id = 100)) UNION SELECT last_name, hire_date,
salary FROM employees WHERE hire_date > SYSDATE -180;
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 68/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Examine the structure of the PROMOTIONS table: (Choose the best answer.)
A. DATE
B. NUMBER
C. TIMESTAMP
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 69/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. Subquery
B. Self-join
Which two are the minimal requirements for a self-join? (Choose two.)
E. The table used for the self-join must have two different alias names in the query.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 70/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which three SQL statements would display the value 1890.55 as $1,890.55? (Choose three.)
A. There is only one subquery in the outer query and the inner query returns one or more values
C. The inner query uses an aggregating function and returns one or more values.
D. The inner query returns one or more values and the outer query returns a single value.
You must write a query that prompts users for column names and conditions every time it is executed.
The user must be prompted only once for the table name.
Which statement achieves those objectives?
Which three statements are true regarding single-row functions? (Choose three.)
A. The data type returned, can be different from the data type of the argument that is referenced.
B. They can return multiple values of more than one data type.
F. They can accept column names, expressions, variable names, or a user-supplied constants as arguments.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 71/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure in the DEPARTMENTS tables. (Choose two.)
WHERE departments_id=90 -
UNION -
SELECT department_id, department_name DEPT_NAME, 'a' FROM
departments
WHERE department_id=10 -
Which two ORDER BY clauses can be used to sort the output?
A. ORDER BY DEPT_NAME;
B. ORDER BY DEPT_ID;
C. ORDER BY 'b';
D. ORDER BY 3;
Which two statements are true regarding the WHERE and HAVING clauses in a SELECT statement? (Choose two.)
A. The WHERE and HAVING clauses can be used in the same statement only if they are applied to different columns in the table.
B. The aggregate functions and columns used in the HAVING clause must be specified in the SELECT list of the query.
C. The WHERE clause can be used to exclude rows after dividing them into groups.
E. The WHERE clause can be used to exclude rows before dividing them into groups.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 72/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You must create a table EMPLOYEES in which the values in the columns EMPLOYEES_ID and LOGIN_ID must be unique and not null.
Which two SQL statements would create the required table? (Choose two.)
A. CREATE TABLE employees (employee_id NUMBER, login_id NUMBER, employee_name VARCHAR2(100), hire_date DATE, CONSTRAINT
emp_id_uk UNIQUE (employee_id, login_id));
B. CREATE TABLE employees (employee_id NUMBER, login_id NUMBER, employee_name VARCHAR2(25), hire_date DATE, CONSTRAINT
emp_id_pk PRIMARY KEY (employee_id, login_id));
C. CREATE TABLE employees (employee_id NUMBER CONSTRAINT emp_id_pk PRIMARY KEY, login_id NUMBER UNIQUE, employee_name
VARCHAR2(25), hire_date DATE);
D. CREATE TABLE employees (employee_id NUMBER, login_id NUMBER, employee_name VARCHAR2(100), hire_date DATE, CONSTRAINT
emp_id_uk UNIQUE (employee_id, login_id); CONSTRAINT emp_id_nn NOT NULL (employee_id, login_id));
E. CREATE TABLE employees (employee_id NUMBER CONSTRAINT emp_id_nn NOT NULL, login_id NUMBER CONSTRAINT login_id_nn NOT
NULL, employee_name VARCHAR2(100), hire_date DATE, CONSTRAINT emp_num_id_uk UNIQUE (employee_id, login_id));
View the Exhibit and examine the structure of the PRODUCT_INFORMATION table. (Choose the best answer.)
A. SELECT product_id, UPPER(product_name) FROM product_information WHERE UPPER(product_name) = 'LASERPRO' OR list_price > 1000;
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 73/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. A set of one or more sequential queries in which generally the result of the inner query is used as the search value in the outer query.
B. A set of sequential queries, all of which must return values from the same table.
C. A set of sequential queries, all of which must always return a single value.
D. A SELECT statement that can be embedded in a clause of another SELECT statement only.
C. The subquery and main query must retrieve date from the same table.
D. The subquery and main query can retrieve data from different tables.
E. Only one column or expression can be compared between the subquery and main query.
F. Multiple columns or expressions can be compared between the subquery and main query.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 74/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
See the Exhibit and examine the structure of the PROMOTIONS table:
A. It generates an error because multiple conditions cannot be specified for the WHEN clause.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 75/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements are true regarding multiple-row subqueries? (Choose two.)
C. They use the < ALL operator to imply less than the maximum.
D. They can be used to retrieve multiple rows from a single table only.
E. They should not be used with the NOT IN operator in the main query if NULL is likely to be a part of the result of the subquery.
View the Exhibit and examine the structure of the CUSTOMERS and CUST_HISTORY tables.
The CUSTOMERS table contains the current location of all currently active customers.
The CUST_HISTORY table stores historical details relating to any changes in the location of all current as well as previous customers who are
no longer active with the company.
You need to find those customers who have never changed their address.
Which SET operator would you use to get the required output?
A. INTERSECT
B. UNION ALL
C. MINUS
D. UNION
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 76/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You executed the following query to display PRODUCT_NAME and the number of times the product has been ordered:
SELECT p.product_name, i.item_cnt
FROM (SELECT product_id, COUNT (*) item_cnt
FROM order_items -
GROUP BY product_id) i RIGHT OUTER JOIN products p
ON i.product_id = p.product_id;
What would happen when the above statement is executed?
B. The statement would not execute because inline views and outer joins cannot be used together.
C. The statement would not execute because the ITEM_CNT alias cannot be displayed in the outer query.
D. The statement would not execute because the GROUP BY clause cannot be used in the inline.
D. The number of columns selected in all select statements need not be the same.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 77/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
B. All indexes and constraints defined on the table being dropped are also dropped.
Examine the create table statements for the stores and sales tables.
SQL> CREATE TABLE stores(store_id NUMBER(4) CONSTRAINT store_id_pk PRIMARY KEY, store_name VARCHAR2(12), store_address
VARCHAR2(20), start_date DATE);
SQL> CREATE TABLE sales(sales_id NUMBER(4) CONSTRAINT sales_id_pk PRIMARY KEY, item_id NUMBER(4), quantity NUMBER(10),
sales_date DATE, store_id NUMBER(4), CONSTRAINT store_id_fk FOREIGN KEY(store_id) REFERENCES stores(store_id));
You executed the following statement:
C. DELETE the rows with STORE_ID = 900 from the SALES table and then delete rows from STORES table.
D. Disable the FOREIGN KEY in SALES table and then delete the rows.
E. Create the foreign key in the SALES table on SALES_ID column with on DELETE CASCADE option.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 78/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
In the customers table, the CUST_CITY column contains the value 'Paris' for the
CUST_FIRST_NAME 'Abigail'.
Evaluate the following query:
A. Abigail PA
B. Abigail Pa
C. Abigail IS
D. An error message
E. All constraints can be defined at the column level and at the table level.
On your Oracle 12c database, you invoked SQL *Loader to load data into the EMPLOYEES table in the HR schema by issuing the following
command:
$> sqlldr hr/hr@pdb table=employees
Which two statements are true regarding the command?
A. It succeeds with default settings if the EMPLOYEES table belonging to HR is already defined in the database.
C. It fails if the HR user does not have the CREATE ANY DIRECTORY privilege.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 79/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You notice a performance change in your production Oracle 12c database. You want to know which change caused this performance difference.
Which method or feature should you use?
Which statement is true about Enterprise Manager (EM) express in Oracle Database 12c?
B. You can use EM express to manage multiple databases running on the same server.
C. You can perform basic administrative tasks for pluggable databases by using the EM express interface.
Which two partitioned table maintenance operations support asynchronous Global Index Maintenance in Oracle database 12c?
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 80/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Exhibit 1 -
Exhibit 2 -
You issue the following query to display product name the number of times the product has been sold:
B. The statement produces an error because a subquery in the FROM clause and outer-joins cannot be used together.
C. The statement produces an error because the GROUP BY clause cannot be used in a subquery in the FROM clause.
D. The statement produces an error because ITEM_CNT cannot be displayed in the outer query.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 81/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. It displays details only for members who have borrowed before today with RM as TRANSACTION_TYPE.
B. It displays details for members who have borrowed before today's date with either RM as TRANSACTION_TYPE or MEMBER_ID as A101
and A102.
C. It displays details for only members A101 and A102 who have borrowed before today with RM TRANSACTION_TYPE.
D. It displays details for members who have borrowed before today with RM as TRANSACTION_TYPE and the details for members A101 or
A102.
View the Exhibit and examine the data in the EMPLOYEES table.
Exhibit -
You want to generate a report showing the total compensation paid to each employee to date.
You issue the following query:
B. It generates an error because the concatenation operator can be used to combine only two items.
C. It generates an error because the usage of the ROUND function in the expression is not valid.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 82/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You want to generate a list of all department IDs that do not exist in the COURSE_DETAILS table.
You execute the SQL statement:
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 83/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the details of the PRODUCT_INFORMATION table.
Exhibit -
You must display PRODUCT_NAME from the table where the CATEGORY_ID column has values 12 or 13, and the SUPPLIER_ID column has the
value 102088.
You executed this SQL statement:
A. It would not execute because the entire WHERE clause is not enclosed within parentheses.
C. It would not execute because the same column has been used twice with the AND logical operator.
You need to produce a report where each customer's credit limit has been incremented by $1000. In the output, the customer's last name should
have the heading Name and the incremented credit limit should be labeled New Credit Limit. The column headings should have only the first
letter of each word in uppercase.
Which statement would accomplish this requirement?
A. SELECT cust_last_name AS "Name", cust_credit_limit + 1000 AS "New Credit Limit" FROM customers;
B. SELECT cust_last_name AS Name, cust_credit_limit + 1000 AS New Credit Limit FROM customers;
C. SELECT cust_last_name AS Name, cust_credit_limit + 1000 "New Credit Limit" FROM customers;
D. SELECT INITCAP (cust_last_name) "Name", cust_credit_limit + 1000 INITCAP ("NEW CREDIT LIMIT") FROM customers;
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 84/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the ORDERS table.
A. UPDATE orders SET order_date = '12-mar-2007', order_total IS NULL WHERE order_id = 2455;
B. UPDATE orders SET order_date = '12-mar-2007', AND order_total = TO_NUMBER(NULL) WHERE order_id = 2455;
C. UPDATE orders SET order_date = '12-mar-2007', order_total = NULL WHERE order_id = 2455;
D. UPDATE orders SET order_date = TO_DATE('12-mar-2007','dd-mon-yyyy'), SET order_total = TO_NUMBER (NULL) WHERE order_id = 2455;
SCOTT -
Evaluate the commands issued by the DBA:
A. Statement 1 would not execute because the WITH GRANT option is missing.
B. Statement 2 would not execute because system privileges and object privileges cannot be granted together in a single GRANT command.
C. Statement 3 would not execute because role and system privileges cannot be granted together in a single GRANT statement.
D. Statement 1 would not execute because the IDENTIFIED BY <password> clause is missing.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 85/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the data in the PRODUCT_INFORMATION table.
A. displaying all the products whose minimum list prices are more than average list price of products having the status orderable
B. displaying the total number of products supplied by supplier 102071 and having product status OBSOLETE
C. displaying the number of products whose list prices are more than the average list price
D. displaying all supplier IDs whose average list price is more than 500
View the Exhibit and examine the description of the EMPLOYEES table.
You want to calculate the total remuneration for each employee. Total remuneration is the sum of the annual salary and the percentage
commission earned for a year. Only a few employees earn commission.
Which SQL statement would you execute to get the desired output?
C. SELECT first_name, salary (salary + NVL (commission_pct, 0)*salary)*12 "Total" FROM EMPLOYEES;
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 86/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the PROMOTIONS table.
A. It produces an error because subqueries cannot be used with the CASE expression.
B. It shows COST_REMARK for all the promos in the promo category "˜TV'.
Which statement is true regarding the USING clause in table joins? (Choose two.)
B. It can be used to access data from tables through equijoins as well as nonequijoins.
C. It can be used to join tables that have columns with the same name and compatible data types.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 87/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements are true regarding the storage of data in the above table structure? (Choose two.)
A. The CUST_CREDIT_VALUE column would allow storage of positive and negative integers.
B. The TRANS_VALIDITY column would allow storage of a time interval in days, hours, minutes, and seconds.
C. The CUST_STATUS column would allow storage of data up to the maximum VARCHAR2 size of 4,000 characters.
D. The TRANS_DATE column would allow storage of dates only in the dd-mon-yyyy format.
A. SELECT SUM(DISTINCT NVL(subject1,0)), MAX(subject1) FROM marks WHERE subject1 > subject2;
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 88/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You want to list all cities that have more than one customer along with the customer details.
Evaluate the following query:
Which two JOIN options can be used in the blank in the above query to give the correct output? (Choose two.)
B. JOIN
C. NATURAL JOIN
Which two statements are true regarding the creation and storage of data in the above table structure? (Choose two.)
E. The TRANS_DATE column would be able to store day, month, century, year, hour, minutes, seconds, and fractions of seconds.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 89/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the PRODUCT_INFORMATION and INVENTORIES tables.
You have a requirement from the supplies department to give a list containing PRODUCT_ID, SUPPLIER_ID, and QUANTITY_ON_HAND for all the
products wherein QUANTITY_ON_HAND is less than five.
Which two SQL statements can accomplish the task? (Choose two.)
B. SELECT product_id, quantity_on_hand, supplier_id FROM product_information NATURAL JOIN inventories AND quantity_on_hand < 5;
D. SELECT i.product_id, i.quantity_on_hand, pi.supplier_id FROM product_information pi JOIN inventories i USING (product_id) AND
quantity_on_hand < 5;
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 90/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
In the EMPLOYEES table there are 1000 rows and employees are working in the company for more than 10 years.
Evaluate the following SQL statement:
B. It executes successfully and updates the records of those employees who have been working in the company for more than 600 days.
Which statement adds a column called SALARY to the EMPLOYEES table having 100 rows, which cannot contain null?
B. ALTER TABLE EMPLOYEES ADD SALARY NUMBER(8,2) DEFAULT CONSTRAINT p_nn NOT NULL;
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 91/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the data in the PROMOTIONS table.
mon-rr.
PROMO_BEGIN_DATE -
You need to produce a report that provides the name, cost, and start date of all promos in the POST category that were launched before January
1, 2000.
Which SQL statement would you use?
A. SELECT promo_name, promo_cost, promo_begin_date FROM promotions WHERE promo_category = 'post' AND promo_begin_date < '01-
01-00';
B. SELECT promo_name, promo_cost, promo_begin_date FROM promotions WHERE promo_category LIKE 'P%' AND promo_begin_date < '1-
JANUARY-00';
C. SELECT promo_name, promo_cost, promo_begin_date FROM promotions WHERE promo_cost LIKE 'post%' AND promo_begin_date < '01-
01-2000';
D. SELECT promo_name, promo_cost, promo_begin_date FROM promotions WHERE promo_category LIKE '%post%' AND promo_begin_date <
'1-JAN-00';
A. The WITH CHECK OPTION constraint can be used in a view definition to restrict the columns displayed through the view.
B. The OR REPLACE option is used to change the definition of an existing view without dropping and re-creating it.
C. Rows cannot be deleted through a view if the view definition contains the DISTINCT keyword.
D. Rows added through a view are deleted from the table automatically when the view is dropped.
E. A simple view in which column aliases have been used cannot be updated.
F. A subquery used in a complex view definition cannot contain group functions or joins.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 92/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. It produces an error because the condition on the CUST_CITY column is not valid.
B. It produces an error because the condition on the CUST_FIRST_NAME column is not valid.
C. It produces an error because conditions on the CUST_CREDIT_LIMIT column are not valid.
D. It executes successfully.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 93/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
INCREMENT BY 10 -
MAXVALUE 200 -
CYCLE -
NOCACHE;
The sequence SEQ1 has generated numbers up to the maximum limit of 200. You issue the following SQL statement:
SELECT seq1.nextval FROM dual;
What is displayed by the SELECT statement?
A. 100
B. an error
C. 10
D. 1
A. It contains the object privileges granted to other users by the current user session.
B. It contains the system privileges granted to other users by the current user session.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 94/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You want to update this table such that BOOK_ID is set to 'INVALID' for all rows where no MEMBER_ID has been entered.
Examine this partial SQL statement:
Which condition must be used in the WHERE clause to perform the required update?
A. MEMBER_ID = '';
B. MEMBER_ID = NULL;
C. MEMBER_ID IS NULL;
D. MEMBER_ID = "";
The command to create a table fails. Identify the reason for the SQL statement failure.
A. You cannot use ORD_NO and ITEM_NO columns as a composite primary key because ORD_NO is also the FOREIGN KEY.
B. You cannot use the BETWEEN clause in the condition of a CHECK constraint.
C. You cannot use the NEXTVAL sequence value as a DEFAULT value for a column.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 95/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
B. It executes successfully and displays the literal " {'s start date was \> " for each row in the output.
C. It executes successfully and introduces an 's at the end of each promo_name in the output.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 96/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit and examine the description for the SALES and CHANNELS tables.
A. The statement will fail because the subquery in the VALUES clause is not enclosed within single quotation marks.
B. The statement will fail because a subquery cannot be used in a VALUES clause.
C. The statement will fail because the VALUES clause is not required with a subquery.
D. The statement will execute and a new row will be inserted in the SALES table.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 97/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the CUSTOMERS table.
A. It returns an error because the BETWEEN operator cannot be used in the HAVING clause.
B. It returns an error because WHERE and HAVING clauses cannot be used in the same SELECT statement.
C. It returns an error because WHERE and HAVING clauses cannot be used to apply conditions on the same column.
D. It executes successfully.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 98/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the details of the ORDER_ITEMS table.
FROM order_items -
GROUP BY order_id;
Which statements are true regarding the output of these SQL statements? (Choose all that apply.)
B. Both statements would ignore NULL values for the UNIT_PRICE and QUANTITY columns.
B. A subquery in the WHERE clause of a SELECT statement can be nested up to three levels only.
C. A subquery can be used to access data from one or more tables or views.
D. The columns in a subquery must always be qualified with the name or alias of the table used.
E. If the subquery returns 0 rows, then the value returned by the subquery expression is NULL.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 99/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements are true regarding SQL statements that can be executed on the EMP_DETAIL TABLE?
B. You can alter the table to include the NOT NULL constraint on the EMP_IMAGE column.
C. You cannot add a new column to the table with LONG as the data type.
View the Exhibit and examine the structure of ORDER_ITEMS and ORDERS tables.
You need to remove from the ORDER_ITEMS table those rows that have an order status of 0 or 1 in the ORDERS table.
Which two DELETE statements are valid (Choose two.)
A. DELETE * FROM order_items WHERE order_id IN (SELECT order_id) FROM orders WHERE order_status IN (0,1));
B. DELETE FROM (SELECT * FROM order_items I,orders o WHERE i.order_id = o.order_id AND order_status IN (0,1));
C. DELETE FROM order_items i WHERE order_id = (SELECT order_id FROM orders o WHERE i.order_id = o.order_id AND order_status IN
(0,1));
D. DELETE FROM order_items WHERE order_id IN (SELECT order_id FROM orders WHERE orders_status in (0,1));
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 100/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You executed the following CREATE TABLE statement that resulted in an error:
SQL> CREATE TABLE employees(emp_id NUMBER(10) PRIMARY KEY, ename VARCHAR2(20), email NUMBER(3) UNIQUE, address VARCHAR2
(500), phone VARCHAR2(20), resume LONG, hire_date DATE, remarks LONG, dept_id NUMBER(3) CONSTRAINT emp_dept_id_fk
REFERENCES departments (dept_id), CONSTRAINT ename_nn NOY NULL(ename));
Identify two reasons for the error.
A. The NOT NULL constraint on the ENAME column must be defined as the column level
B. FOREIGN KEY defined on the DEPT_ID column must be at the table level only
E. The PRIMARY KEY constraint in the EMP_ID column must have a name and must be defined at the table level only
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 101/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the CUSTOMERS table.
You want to generate a report showing the last names and credit limits of all customers whose last names start with A, B, or C, and credit limit
is below 10,000.
Evaluate the following two queries:
SQL> SELECT cust_last_name, cust_credit_limit FROM customers
WHERE (UPPER(cust_last_name) LIKE "˜A%' OR
UPPER (cust_last_name) LIKE "˜B%' OR UPPER (cust_last_name) LIKE "˜C%')
AND cust_credit_limit < 10000;
SQL>SELECT cust_last_name, cust_credit_limit FROM customers
WHERE UPPER (cust_last_name) BETWEEN "˜A' AND "˜C'
AND cust_credit_limit < 10000;
Which statement is true regarding the execution of the above queries?
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 102/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
CREATE_TABLE orders -
(ord_no NUMBER (2) CONSTRAINT ord_pk PRIMARY KEY,
ord_date DATE,
cust_id NUMBER (4));
B. The BETWEEN clause cannot be used twice for the same table.
C. The CHECK constraint cannot be placed on columns having the DATE data type.
D. ORD_NO and ITEM_NO cannot be used as a composite primary key because ORD_NO is also the FOREIGN KEY.
View the Exhibit and examine the structure of the PRODUCT table.
A. display all products whose minimum list price is more than the average list price of products having the status "˜orderable'
B. display the total number of products supplied by supplier 102 and have product status as "˜OBSOLETE'
C. display the number of products whose list prices are more than the average list price
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 103/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. SELECT e.last_name, e.hire_date, NVL(m.last_name, "˜No Manager') Manager FROM employees e JOIN employees m ON (e.manager_id =
m.employee_id);
B. SELECT e.last_name, e.hire_date, NVL(m.last_name, "˜No Manager') Manager FROM employees e LEFT OUTER JOIN employees m ON
(e.manager_id = m.employee_id);
C. SELECT e.last_name, e.hire_date, NVL(m.last_name, "˜No Manager') Manager FROM employees e RIGHT OUTER JOIN employees m ON
(e.manager_id = m.employee_id);
D. SELECT e.last_name, e.hire_date, NVL(m.last_name, "˜No Manager') Manager FROM employees e NATURAL JOIN employees m ON
(e.manager_id = m.employee_id).
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 104/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of ORDERS and CUSTOMERS tables.
There is only one customer with the cust_last_name column having value Roberts. Which INSERT statement should be used to add a row into
the ORDERS table for the customer whose CUST_LAST_NAME is Roberts and CREDIT_LIMIT is 600?
A. INSERT INTO orders VALUES(1, '10-mar-2007', "˜direct', (SELECT customer_id FROM customers WHERE cust_last_name='Roberts' AND
credit_limit=600), 1000);
B. INSERT INTO orders (order_id, order_data, order_mode, (SELECT customer_id FROM customers WHERE cust_last_name='Roberts' AND
credit_limit=600), order_total) VALUES(1, '10-mar-2007', "˜direct', &&customer_id, 1000);
C. INSERT INTO(SELECT o.order_id, o.order_date, o.order_mode, c.customer_id, o.order_total FROM orders o, customers c WHERE
o.customer_id = c.customer_id AND c.cust_last_name='Roberts' AND c.credit_limit=600 ) VALUES (1, '10-mar-2007', "˜direct', (SELECT
customer_id FROM customers WHERE cust_last_name='Roberts' AND credit_limit=600), 1000);
D. INSERT INTO orders (order_id, order_data, order_mode, (SELECT customer_id FROM customers WHERE cust_last_name='Roberts' AND
credit_limit=600), order_total) VALUES (1, '10-mar-2007', "˜direct', &customer_id, 1000).
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 105/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the data in EMP and DEPT tables.
A. Both the INSERT statements would fail because the constraints are automatically retrieved when the table is flashed back.
B. Both the INSERT statements would succeed because none of the constraints on the table are automatically retrieved when the table is
flashed back.
C. Only the first INSERT statement would succeed because all constraints except the primary key constraint are automatically retrieved
after a table is flashed back.
D. Only the SECOND INSERT statement would succeed because all the constraints except referential integrity constraints that reference
other tables are retrieved automatically after the table is flashed back.
B. modifying a table to prevent data that violate certain conditions from being entered in a column
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 106/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the ORDER_ITEMS and ORDERS tables.
You are asked to retrieve the ORDER_ID, product_ID, and total price (UNIT_PRICE multiplied by QUANTITY), where the total price is greater than
50,000.
You executed the following SQL statement:
prder_id, product_id, unit_price*quantity "Total Price"
SELECT -
FROM order_items -
WHERE unit_price*quantity > 50000
NATURAL JOIN orders;
Which statement is true regarding the execution of the statement?
B. The statement would not execute because the ON keyword is missing in the NATURAL JOIN clause.
C. The statement would not execute because the WHERE clause is before the NATURAL JOIN clause.
D. The statement would not execute because the USING keyword is missing in the NATURAL JOIN clause.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 107/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements are true regarding operators used with subqueries (Choose two.)
E. The NOT operator can be used with IN, ANY and ALL operators.
You want to generate a report that displays the PO_ID and the penalty amount to be paid if the SHIPMENT_DATE is later than one month from
the PO_DATE. The penalty is $20 per day.
Evaluate the following two queries:
B. Only the first query executes successfully but gives a wrong result.
C. Only the first query executes successfully and gives the correct result.
D. Only the second query executes successfully but gives a wrong result.
E. Only the second query executes successfully and gives the correct result.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 108/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You plan to give a discount of 25% on the product price and need to display the discount amount in the same format as the PROD_PRICE.
Which SQL statement would give the required result?
View the Exhibit and examine the data in the PRODUCTS table.
Which statement would add a column called PRICE, which cannot contain NULL?
D. ALTER TABLE products ADD price NUMBER(8,2) DEFAULT CONSTRAINT p_nn NOT NULL.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 109/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. SELECT cust_first_name, cust_credit_limit * .05 AS TAX_AMOUNT FROM customers WHERE cust_income_level IS NOT NULL AND
tax_amount IS NOT NULL;
B. SELECT cust_first_name, cust_credit_limit * .05 AS TAX_AMOUNT FROM customers WHERE cust_income_level IS NOT NULL AND
cust_credit_limit IS NOT NULL;
C. SELECT cust_first_name, cust_credit_limit * .05 AS TAX_AMOUNT FROM customers WHERE cust_income_level <> NULL AND tax_amount
<> NULL;
D. SELECT cust_first_name, cust_credit_limit * .05 AS TAX_AMOUNT FROM customers WHERE (cust_income_level, tax_amount) IS NOT
NULL;
View the Exhibit and examine the structure of the SALES table.
The following query is written to retrieve all those product IDs from the SALES table that have more than 55000 sold and have been ordered
more than 10 items.
B. It produces an error because COUNT (*) should be specified in the SELECT clause also.
C. It produces an error because COUNT (*) should be only in the HAVING clause and not in the WHERE clause.
D. It executes successfully but produces no result because COUNT(prod_id) should be used instead of COUNT(*).
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 110/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the description for the PRODUCTS and SALES table.
is a primary key in the PRODUCTS table and foreign key in the SALES table with ON DELETE CASCADE option. The SALES table contains data
for the
PROD_ID -
last three years. You want to remove all the rows from the PRODUCTS table for which no sale was done for the last three years.
Which is the valid DELETE statement?
A. DELETE FROM products WHERE prod_id = (SELECT prod_id FROM sales WHERE time_id - 3*365 = SYSDATE );
B. DELETE FROM products WHERE prod_id = (SELECT prod_id FROM sales WHERE SYSDATE >= time_id - 3*365 );
C. DELETE FROM products WHERE prod_id IN (SELECT prod_id FROM sales WHERE SYSDATE - 3*365 >= time_id);
D. DELETE FROM products WHERE prod_id IN (SELECT prod_id FROM sales WHERE time_id >= SYSDATE - 3*365 );
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 111/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You want to extract only those customer names that have three names and display the * symbol in place of the first name as follows:
A. SELECT LPAD(SUBSTR(cust_name, INSTR(cust_name, ' ')),LENGTH(cust_name),'*') "CUST NAME" FROM customers WHERE
INSTR(cust_name, ' ',1,2)<>0;
B. SELECT LPAD(SUBSTR(cust_name, INSTR(cust_name, ' ')),LENGTH(cust_name),'*') "CUST NAME" FROM customers WHERE
INSTR(cust_name, ' ',-1,2)<>0;
C. SELECT LPAD(SUBSTR(cust_name, INSTR (cust_name ' ')),LENGTH(cust_name) - INSTR(cust_name, ' '), '*') "CUST NAME" FROM
customers WHERE INSTR(cust_name, ' ',1,-2)<>0;
D. SELECT LPAD(SUBSTR(cust_name, INSTR (cust_name ' ')),LENGTH(cust_name) - INSTR(cust_name, ' '), '*') "CUST NAME" FROM
customers WHERE INSTR(cust_name, ' ',1,2)<>0;
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 112/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the BOOKS table.
A. Both ROLLBACK commands restore the 101 rows that were deleted.
B. Both ROLLBACK commands restore the 100 rows that were deleted.
C. The first rollback restores the 101 rows that were deleted and the second rollback causes the row was inserted to be deleted and
commits the changes.
D. The first rollback restores the 100 rows that were deleted and the second rollback commits only the changes.
Which statement is true about the Oracle SQL, DELETE and TRUNCATE statements?
A. DELTE and TRUNCATE statements can have a rollback done to restore data into a table.
B. DELETE and TRUNCATE statements remove all indexes for the tables on which they are performed.
C. DELETE but not TRUNCATE statement can be used to remove data from selective columns and rows of a table.
D. DELETE but not TRUNCATE statement can be used to selectively remove rows from a table.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 113/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the description of the EMPLOYEES table.
B. The query would not execute because date functions cannot be nested.
C. The query would execute but the output would give review dates that are Sundays.
D. The query would not execute because the NEXT_DAY function accepts a string as argument.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 114/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the CUSTOMERS table.
CUSTOMERS table.
CUSTOMER_VU -
need to be updated to reflect the latest information about the customers.
CUSTOMERS -
What is the error in the following MERGE statement?
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 115/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
B. It produces an error because positional notation cannot be used in the ORDER BY clause with SET operators.
C. It executes successfully but ignores the ORDER BY clause because it is not located at the end of the compound statement.
D. It produces an error because the ORDER BY clause should appear only at the end of a compound query-that is, with the last SELECT
statement.
View the Exhibit and examine the structure of the ORDERS table. The columns ORDER_MODE and ORDER_TOTAL have the default values
"˜direct' and 0 respectively.
B. INSERT INTO orders (order_id,order_date,order_mode, (customer_id,order_total) VALUES (1,TO_DATE(NULL), "˜online', 101, NULL);
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 116/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
B. The user SYSTEM owns all the base tables and user-accessible views of the data dictionary.
C. All the dynamic performance views prefixed with v$ are accessible to all the database users.
D. The USER_OBJECTS view can provide information about the tables and views created by the user who queries the view.
E. DICTIONARY is a view that contains the names of all the data dictionary views that the user can access.
What is the primary difference between the relational database (RDB) and object-oriented database (OODB) models?
A. OODB supports multiple objects in the same database, whereas RDB supports only tables.
B. RDB supports only E.F. Codd's rules, whereas OODB does not support them.
C. OODB incorporates methods with data structure definition, whereas RDB does not allow this.
D. RDB allows the definition of relationships between different tables, whereas OODB does not allow this.
C. It executes successfully only if the PUBLISHER_ID column name is added to the columns list in the INSERT statement.
D. It executes successfully only if the PUBLISHER_ID column name is added to the columns list and NULL is explicitly specified in the
INSERT statement.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 117/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You need to list the employees in DEPARTMENT_ID 20 days in a single row, ordered by HIRE_DATE.
Examine the sample output:
A. SELECT LISTAGG(last_name) WITHIN GROUP ORDER BY (hire_date) "Emp_list", MIN(hire_date) "Earliest" FROM employees WHERE
department_id = 30;
B. SELECT LISTAGG(last_name, '; ') WITHIN GROUP ORDER BY (hire_date) "Emp_list", MIN(hire_date) "Earliest" FROM employees WHERE
department_id = 30;
C. SELECT LISTAGG(last_name, '; ') "Emp_list", MIN(hire_date) "Earliest" FROM employees WHERE department_id = 30; WITHIN GROUP
ORDER BY (hire_date);
D. SELECT LISTAGG(last_name, '; ') "Emp_list", MIN(hire_date) "Earliest" FROM employees WHERE department_id = 30; ORDER BY
(hire_date);
C. Views created in the DEPARTMENTS table that include the COUNTRY column are automatically modified and remain valid.
D. Indexes created on the COUNTRY column exist until the DROP UNUSED COLUMNS command is executed.
E. A new column, COUNTRY, can be added to the DEPARTMENTS table after executing the command.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 118/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit and examine the description of SALES and PROMOTIONS tables.
You want to delete rows from the SALES table, where the PROMO_NAME column in the PROMOTIONS table has either blowout sale or everyday
low price as values.
Which three DELETE statements are valid? (Choose three.)
A. DELETE FROM sales WHERE promo_id = (SELECT promo_id FROM promo_name = "˜blowout sale') AND promo_id = (SELECT promo_id
FROM promotions WHERE promo_name = "˜everyday low price') FROM promotions WHERE promo_name = "˜everyday low price');
B. DELETE FROM sales WHERE promo_id = (SELECT promo_id FROM promotions WHERE promo_name = "˜blowout sale') OR promo_id =
(SELECT promo_id FROM promotions WHERE promo_name = "˜everyday low price')
C. DELETE FROM sales WHERE promo_id = (SELECT promo_id FROM promotions WHERE promo_name = "˜blowout sale') OR promo_name =
"˜everyday low price');
D. DELETE FROM sales WHERE promo_id IN (SELECT promo_id FROM promotions WHERE promo_name IN = "˜blowout sale',"˜everyday low
price'));
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 119/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You need to display the first names of all customers from the CUSTOMERS table that contain the character "˜e' and have the character "˜a' in
the second last position.
Which query would give the required output?
A. SELECT cust_first_name FROM customers WHERE INSTR(cust_first_name, "˜e')<>0 AND SUBSTR(cust_first_name, -2, 1)='a';
B. SELECT cust_first_name FROM customers WHERE INSTR(cust_first_name, "˜e')<>'' AND SUBSTR(cust_first_name, -2, 1)='a';
C. SELECT cust_first_name FROM customers WHERE INSTR(cust_first_name, "˜e')IS NOT NULL AND SUBSTR(cust_first_name, 1, -2)='a';
A. It returns an error because the HAVING clause should be specified after the GROUP BY clause.
B. It returns an error because all the aggregate functions used in the HAVING clause must be specified in the SELECT list.
C. It displays the item nos with their average quantity where the average quantity is more than double the minimum quantity of that item in
the table.
D. It displays the item nos with their average quantity where the average quantity is more than double the overall minimum quantity of all
the items in the table.
Which two statements are true regarding the DELETE and TRUNCATE commands?
A. DELETE can be used to remove rows from only one table in one statement.
B. DELETE can be used to remove rows from multiple tables in one statement.
C. DELETE can be used to remove rows only for tables that are parents for a child table that has a referential integrity constraint referring to
the parent.
D. DELETE can be used to remove data from specific columns as well as complete rows.
E. DELETE and TRUNCATE can be used for tables that are parents for a child table that has a referential integrity constraint having an ON
DELETE rule.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 120/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements describe the consequences of issuing the ROLLBACK TO SAVE POINT a command in the session? (Choose two.)
E. Both the DELETE statements and the UPDATE statement are rolled back.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 121/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the PRODUCT_INFORMATION table.
You want to see the product names and the date of expiration of warranty for all the products, if the product is purchased today. The products
that have no warranty should be displayed at the top and the products with maximum warranty period should be displayed at the bottom.
Which SQL statement would you execute to fulfill this requirement?
A. SELECT product_name, SYSDATE+warranty_period AS "Warranty expire date" FROM product_information ORDER BY SYSDATE-
warranty_period
C. SELECT product_name, SYSDATE+warranty_period AS "Warranty expire date" FROM product_information ORDER BY SYSDATE
D. SELECT product_name, SYSDATE+warranty_period AS "Warranty expire date" FROM product_information WHERE warranty_period >
SYSDATE
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 122/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
For customers whose income level has a value, you want to display the first name and due amount as 5% of their credit limit. Customers whose
due amount is null should not be displayed.
Which query should be used?
A.
B.
C.
D.
E.
B. PRODUCT_PRICE can be used in an arithmetic expression even if it has no value stored in it.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 123/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. The SYS user owns all base tables and user-accessible views in the data dictionary.
B. All users have permissions to access all information in the data dictionary by default.
C. The data dictionary is constantly updated to reflect changes to database objects, permissions, and data.
A. Views can join tables only if they belong to the same schema.
B. A view can be created that refers to a non-existent table in its defining query.
E. Rows inserted into a table using a view are retained in the table if the view is dropped.
F. A SELECT statement cannot contain a WHERE clause when querying a view containing a WHERE clause in its defining query.
You need to display last names and credit limits of all customers whose last name starts with A or B in lower or upper case, and whose credit
limit is below 1000.
Examine this partial query:
A.
B.
C.
D.
E.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 124/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
You want to display the CUST_NAME values where the last name starts with Mc or MC.
Which two WHERE clauses give the required result?
D. WHERE SUBSTR (cust_name, INSTR (cust_name, "˜') +1) LIKE "˜Mc%' OR "˜MC%'
A. It can combine rows from multiple tables conditionally to insert into a single table.
E. It can update the same row of the target table multiple times.
Which three actions can you perform only with system privileges?
B. Log in to a database.
C. Access flat files via a database, which are stored in an operating system directory.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 125/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
D. They can insert each computed row into more than one table.
A. SALES1 has NOT NULL constraints on any selected columns which had those constraints in the SALES table.
C. SALES1 has PRIMARY KEY and UNIQUE constraints on any selected columns which had those constraints in the SALES table.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 126/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements are true about the results of using the INTERSECT operator in compound queries?
B. Reversing the order of the intersected tables can sometimes affect the output.
C. The number of columns in each SELECT in the compound query can be different.
CUSTNO -
You must determine if any customers' details have been entered more than once using a different CUSTNO, by listing all duplicate names.
Which two methods can you use to get the required result?
B. self join
E. subquery
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 127/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A.
B.
C.
D.
The SALES table has columns PROD_ID and QUANTITY_SOLD of data type NUMBER.
Which two queries execute successfully?
A. SELECT prod_id FROM sales WHERE quantity_sold > 55000 GROUP BY prod_id HAVING COUNT(*) >10;
B. SELECT prod_id FROM sales WHERE quantity_sold > 55000 AND COUNT(*) > 10 GROUP BY prod_id HAVING COUNT(*) >10;
C. SELECT COUNT (prod_id) FROM sales WHERE quantity_sold > 55000 GROUP BY prod_id;
D. SELECT prod_id FROM sales WHERE quantity_sold > 55000 AND COUNT(*) > 10 GROUP BY COUNT(*) >10;
E. SELECT COUNT(prod_id) FROM sales GROUP BY prod_id WHERE quantity_sold > 55000;
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 128/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
B. A column that is referenced by another column in any other table cannot be dropped.
D. Multiple columns can be dropped simultaneously using the ALTER TABLE command.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 129/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
The EMPLOYEES table contains columns EMP_ID of data type NUMBER and HIRE_DATE of data type DATE.
You want to display the date of the first Monday after the completion of six month since hiring.
The NLS_TERRITORY parameter is set to AMERICA in the session and, therefore, Sunday is the first day of the week.
Which query can be used?
Which two statements are true about date/time functions in a session where NLS_DATE_FORMAT is set to DD-MON-YYYY HH24:MI:SS?
B. CURRENT_TIMESTAMP returns the same date and time as SYSDATE with additional details of fractional seconds.
C. SYSDATE and CURRENT_DATE return the current date and time set for the operating system of the database server.
D. SYSDATE can be used in expressions only if the default date format is DD-MON-RR.
F. CURRENT_DATE returns the current date and time as per the session time zone.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 130/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which three statements are true about the Oracle join and ANSI join syntax?
B. The Oracle join syntax performs less well than the SQL:1999 compliant ANSI join syntax.
C. The Oracle join syntax supports creation of a Cartesian product of two tables.
E. The Oracle join syntax performs better than the SQL:1999 compliant ANSI join syntax.
G. The SQL:1999 compliant ANSI join syntax supports creation of a Cartesian product of two tables.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 131/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. The statement will execute successfully and a new row will be inserted into the SALES table.
C. The statement will fail because a subquery may not be contained in a VALUES clause.
D. The statement will fail if a row already exists in the SALES table for product 23.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 132/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
The STATUS column contains the values "˜IN STOCK' or "˜OUT OF STOCK' for each row.
Which two queries will execute successfully?
A.
B.
C.
D.
E.
F.
You want to display details of all customers who reside in cities starting with the letter D followed by at least two characters.
Which query can be used?
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 133/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
C. The DELETE statement executes successfully even if the subquery selects multiple rows.
A. The BETWEEN condition always performs less well than using the >= and <= conditions.
D. The BETWEEN condition always performs better than using the >= and <= conditions.
E. The Oracle join syntax performs better than the SQL:1999 compliant ANSI join syntax.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 134/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A.
B.
C.
D.
A. when issuing a TRUNCATE statement after a SELECT statement was issued in the same session
B. when issuing a CREATE INDEX statement after a CREATE TABLE statement completed successfully in the same session
C. when issuing a CREATE TABLE statement after a SELECT statement was issued in the same session
D. when issuing the first Data Manipulation Language (DML) statement after a COMMIT or ROLLBACK statement was issued in the same
session
E. when issuing a DML statement after a DML statement failed in the same session
F. when issuing a SELECT FOR UPDATE statement after a CREATE TABLE AS SELECT statement was issued in the same session
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 135/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the Exhibit and examine the structure of the PRODUCT table.
A. display all products whose PROD_MIN_PRICE is more than the average PROD_LIST_PRICE of all products, and whose status is orderable
B. display the total number of products supplied by supplier 102 and have product status as "˜OBSOLETE'
C. display the number of products whose PROD_LIST_PRICE is more than the average PROD_LIST_PRICE.
Which two statements are true regarding the COUNT function? (Choose two.)
A. A SELECT statement using the COUNT function with a DISTINCT keyword cannot have a WHERE clause.
B. COUNT(DISTINCT inv_amt) returns the number of rows excluding rows containing duplicates and NULLs in the INV_AMT column.
C. COUNT(inv_amt) returns the number of rows in a table including rows with NULL in the INV_AMT column.
D. COUNT(*) returns the number of rows including duplicate rows and rows containing NULL value in any column.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 136/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. 0 rows
B. an error
C. 1 row
D. 2 rows
Which query retrieves the number of products with a null list price?
C. The MAX and MIN functions can be used on columns with character data types.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 137/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which three statements are true about time zones, date data types, and timestamp data types in an Oracle database?
A. The DBTIMEZONE function can return an offset from Universal Coordinated Time (UTC).
B. A TIMESTAMP data type column contains information about year, month, and day.
D. A TIMESTAMP WITH LOCAL TIMEZONE data type column is stored in the database using the time zone of the session that inserted the
row.
E. The SESSIONTIMEZONE function can return an offset from Universal Coordinated Time (UTC).
Which statement is true about the INTERSECT operator used in compound queries?
B. Multiple INTERSECT operators are not possible in the same SQL statement.
C. It ignores NULLs.
Which statement is true regarding the default behavior of the ORDER BY clause?
C. Only columns that are specified in the SELECT list can be used in the ORDER BY clause.
D. Numeric values are displayed in descending order if they have decimal positions.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 138/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. It returns the date for the first Monday of the next month.
B. It returns the date for the last Monday of the current month.
D. It generates an error.
A. An object privilege can be granted to other users only by the owner of that object.
B. An object privilege can be granted to a role only by the owner of that object.
C. A table owner must grant the REFERENCES privilege to allow other users to create FOREIGN KEY constraints using that table.
D. The owner of an object acquires all object privileges on that object by default.
E. The WITH GRANT OPTION clause can be used only by DBA users.
A. You can never TRUNCATE a table if foreign key constraints will be violated.
C. For tables with multiple indexes and triggers DELETE is faster than TRUNCATE.
D. You can never DELETE rows from a table if foreign key constraints will be violated.
In the PROMOTIONS table, the PROMO_BEGIN_DATE column is of data type DATE and the default date format is DD-MON-RR.
Which two statements are true about expressions using PROMO_BEGIN_DATE contained a query?
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 139/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
SALES2 -
Some sales data is duplicated in both tables.
You want to display the rows from the SALES1 table which are not present in the SALES2 table.
Which set operator generates the required output?
A. SUBTRACT
B. INTERSECT
C. UNION ALL
D. UNION
E. MINUS
A. 8 rows
B. 1 row
C. 6 rows
D. 3 rows
E. 0 rows
F. an error
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 140/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
The PRODUCT_INFORMATION table has a UNIT_PRICE column of data type NUMBER (8, 2).
Evaluate this SQL statement:
SELECT TO_CHAR(unit_price, "˜$9,999') FROM product_information;
Which two statements are true about the output?
A. A row whose UNIT_PRICE column contains the value 1023.99 will be displayed as $1,024.
B. A row whose UNIT_PRICE column contains the value 10235.99 will be displayed as $1,0236.
C. A row whose UNIT_PRICE column contains the value 10235.99 will be displayed as #######.
D. A row whose UNIT_PRICE column contains the value 10235.99 will be displayed as $1,023.
E. A row whose UNIT_PRICE column contains the value 1023.99 will be displayed as $1,023.
C. WHERE borrowed_date = SYSDATE AND (transaction_type = "˜RM' AND (member_id = A101' OR member_id = "˜A102'));
E. WHERE borrowed_date = SYSDATE AND (transaction_type = "˜RM' AND member_id = "˜A101' OR member_id = "˜A102');
D. It must be an equijoin.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 141/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. Each WHEN condition is tested for each row returned by the subquery.
B. The total number of rows inserted is always equal to the number of rows returned by the subquery.
E. Each row returned by the subquery can be inserted into only a single target table.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 142/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which three statements are true about performing Data Manipulation Language (DML) operations on a view in an Oracle Database?
A. Views cannot be used to add or modify rows in an underlying table if the defining query of the view contains the DISTINCT keyword.
B. Views cannot be used to query rows from an underlying table if the table has a PRIMARY KEY and the PRIMARY KEY columns are not
referenced in the defining query of the view.
C. Views cannot be used to add rows to an underlying table if the table has columns with NOT NULL constraints lacking default values which
are not referenced in the defining query of the view.
D. The WITH CHECK clause has no effect when deleting rows from the underlying table through the view.
F. Views cannot be used to add or modify rows in an underlying table if the defining query of the view contains aggregating functions.
Which two statements are true about the ORDER BY clause when used with a SQL statement containing a SET operator such as UNION?
A. Each SELECT statement in the compound query must have its own ORDER BY clause.
B. Each SELECT statement in the compound query can have its own ORDER BY clause.
D. The first column in the first SELECT of the compound query with the UNION operator is used by default to sort output in the absence of an
ORDER BY clause.
E. Only column names from the first SELECT statement in the compound query are recognized.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 143/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which three statements are true about Data Manipulation Language (DML)?
A. UPDATE statements can have different subqueries to specify the values for each updated column.
A. The first ROLLBACK command restores the 101 rows that were deleted, leaving the inserted row still to be committed.
C. The first ROLLBACK command restores the 101 rows that were deleted and commits the inserted row.
D. A user has all object privileges for every object in their schema by default.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 144/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two methods should you use to prevent prompting for a hire date value when this query is executed?
E. Store the query in a script and pass the substitution value to the script when executing it.
F. Execute the SET VERIFY OFF command before executing the query.
D. It returns matched and unmatched rows from both tables being joined.
E. The Oracle join operator (+) must be used on both sides of the join condition in the WHERE clause.
Which three statements are true about defining relations between tables in a relational database?
B. Every primary or unique key value must refer to a matching foreign key value.
D. Every foreign key value must refer to a matching primary or unique key value.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 145/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two are true about a SQL statement using SET operators such as UNION?
A. The number, but not names, of columns must be identical for all SELECT statements in the query.
B. The data type of each column returned by the second query must be implicitly convertible to the data type of the corresponding column
returned by the first query.
C. The data type group of each column returned by the second query must match the data type group of the corresponding column returned
by the first query.
D. The names and number of columns must be identical for all SELECT statements in the query.
E. The data type of each column returned by the second query must exactly match the data type of the corresponding column returned by
the first query.
Which three statements are true about Structured Query Language (SQL)?
C. It is the only language that can be used for both relational and object-oriented databases.
E. It provides independence for logical data structures being manipulated from the underlying physical data storage
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 146/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements are true about the ORD_ITEMS table and the ORD_SEQ sequence?
A. Sequence ORD_SEQ cycles back to 1 after every 5000 numbers and can cycle 20 times.
B. Any user inserting rows into table ORD_ITEMS must have been granted access to sequence ORD_SEQ.
C. Column ORD_NO gets the next number from sequence ORD_SEQ whenever a row is inserted into ORD_ITEMS and no explicit value is
given for ORD_NO.
D. If sequence ORD_SEQ is dropped then the default value for column ORD_NO will be NULL for rows inserted into ORD_ITEMS.
A. The YEAR field in an INTERVAL YEAR TO MONTH column must be a positive value.
C. INTERVAL YEAR TO MONTH columns only support monthly intervals within a single year.
E. INTERVAL YEAR TO MONTH columns only support monthly intervals within a range of years.
F. The value in an INTERVAL DAY TO SECOND column can be copied into an INTERVAL YEAR TO MONTH column.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 147/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
B. It can be accessed by any user who has the SELECT privilege in any schema.
Which two are true about the WITH GRANT OPTION clause?
A. The grantee must have the GRANT ANY OBJECT PRIVILEGE system privilege to use this option.
F. The grantee can grant the object privilege to any user in the database, with or without including this option.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 148/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two clauses are required for this command to execute successfully?
A. GLOBAL TEMPORARY TABLE rows inserted by a session are available to any other session whose user has been granted select on the
table.
E. Any GLOBAL TEMPORARY TABLE rows existing at session termination will be deleted.
F. A TRUNCATE command issued in a session causes all rows in a GLOBAL TEMPORARY TABLE for the issuing session to be deleted.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 149/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. SELECT customer_id AS "CUSTOMER-ID", transaction_date AS DATE, amount + 100 "DUES" FROM transactions;
B. SELECT customer_id AS CUSTOMER-ID, transaction_date AS TRANS_DATE, amount + 100 "DUES AMOUNT" FROM transactions;
C. SELECT customer_id CUSTID, transaction_date TRANS_DATE, amount +100 DUES FROM transactions;
D. SELECT customer_id AS "CUSTOMER-ID", transaction_date AS "DATE", amount + 100 DUES FROM transactions;
E. SELECT customer_id AS "˜CUSTOMER-ID', transaction_date AS DATE, amount + 100 "˜DUES' FROM transactions;
Which three statements are true about indexes and their administration in an Oracle database?
B. A DROP INDEX statement always prevents updates to the table during the drop operation.
C. A UNIQUE and non-unique index can be created on the same table column.
E. If a query filters on an indexed column then it will always be used during execution of the query.
F. An INVISIBLE index is not maintained when Data Manipulation Language (DML) is performed on its underlying table.
Rows exist in this table with data in all the columns. You put the PRODUCTS table in read-only mode.
Which three commands execute successfully on PRODUCTS?
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 150/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements are true about transactions in the Oracle Database server?
A. If a session has an uncommitted transaction, then a DDL statement issues a COMMIT before starting a new transaction.
D. A user can always see uncommitted updates made by the same user in a different session.
E. A Data Definition Language (DDL) statement does a COMMIT automatically only for the data dictionary updates caused by the DDL.
You want to write a query that prompts for two column names and the WHERE condition each time it is executed in a session but only prompts
for the table name the first time it is executed.
The variables used in your query are never undefined in your session?
Which query can be used?
A.
B.
C.
D.
E.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 151/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Question #1 Topic 2
INSERT ALL -
WHEN order_total < 10000 THEN
INTO small_orders -
WHEN order_total > 10000 AND order_total < 20000 THEN
INTO medium_orders -
WHEN order_total > 200000 AND order_total < 20000 THEN
INTO large_orders -
SELECT order_id, order_total, customer_id
FROM orders;
Which statement is true regarding the evaluation of rows returned by the subquery in the INSERT statement?
A. They are evaluated by all the three WHEN clauses regardless of the results of the evaluation of any other WHEN clause.
B. They are evaluated by the first WHEN clause. If the condition is true, then the row would be evaluated by the subsequent WHEN clauses.
C. They are evaluated by the first WHEN clause. If the condition is false, then the row would be evaluated by the subsequent WHEN clauses.
D. The insert statement would give an error because the ELSE clause is not present for support in case none of WHEN clauses are true.
Question #2 Topic 2
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 152/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Question #3 Topic 2
View the exhibit and examine the structures of the EMPLOYEES and DEPARTMENTS tables.
EMPLOYEES -
Name Null? Type
----------------- ----- -------------
EMPLOYEE_ID NOT NULL NUMBER(6)
FIRST_NAME VARCHAR2(20)
LAST_NAME NOT NULL VARCHAR2(25)
HIRE_DATE NOT NULL DATE
JOB_ID NOT NULL VARCHAR2(10)
SALARY NUMBER(10,2)
COMMISSION NUMBER(6,2)
MANAGER_ID NUMBER(6)
DEPARTMENT_ID NUMBER(4)
DEPARTMENTS -
Name Null? Type
----------------- ----- -------------
DEPARTMENT_ID NOT NULL NUMBER(4)
DEPARTMENT_NAME NOT NULL VARCHAR2(30)
MANAGER_ID NUMBER(6)
LOCATION_ID NUMBER(4)
You want to update EMPLOYEES table as follows:
✑ Update only those employees who work in Boston or Seattle (locations 2900 and 2700).
✑ Set department_id for these employees to the department_id corresponding to London (location_id 2100).
✑ Set the employees' salary in location_id 2100 to 1.1 times the average salary of their department.
✑ Set the employees' commission in location_id 2100 to 1.5 times the average commission of their department.
You issue the following command:
FROM departments -
WHERE location_id = 2100),
(salary, commission) =
(SELECT 1.1*AVG(salary), 1.5*AVG(commission)
WHERE department_id IN -
(SELECT department_id
FROM departments -
A. It generates an error because multiple columns (SALARY, COMMISSION) cannot be specified together in an UPDATE statement.
B. It generates an error because a subquery cannot have a join condition in a UPDATE statement.
Question #4 Topic 2
FROM customers -
WHERE cust_credit_limit IN (1000, 2000, 3000);
SQL> SELECT cust_last_name, cust_city
FROM customers -
WHERE cust_credit_limit = 1000 or cust_credit_limit = 2000 or cust_credit_limit = 3000
Which statement is true regarding the above two queries?
A. Performance would improve in query 2 only if there are null values in the CUST_CREDIT_LIMIT column.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 154/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Question #5 Topic 2
PRODUCT_NAME -
CATEGORY_ID -
SUPPLIER_ID -
Inkjet C/8/HQ -
102094
Inkjet C/4 -
102090
LaserPro 600/6/BW -
102087
LaserPro 1200/8/BW -
102099
Inkjet B/6 -
102096
Industrial 700/ID -
102086
Industrial 600/DQ -
102088
Compact 400/LQ -
102087
Compact 400/DQ -
102088
HD 12GB /R -
102090
HD 10GB /I -
102071
HD 18.2GB @10000 /E -
102078
HD 18.2GB @10000 /I -
102050
HD 18GB /SE -
102083
HD 6GB /I -
102072
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 155/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
HD 8.2GB@5400 -
102093
You have the requirement to display PRODUCT_NAME from the table where the CATEGORY_ID column has values 12 or 13, and the SUPPLIER_ID
column has the value 102088. You executed the following SQL statement:
SELECT product_name -
FROM product_information -
WHERE (category_id = 12 AND category_id = 13) AND supplier_id = 102088;
Which statement is true regarding the execution of the query?
A. It would not execute because the same column has been used in both sides of the AND logical operator to form the condition.
B. It would not execute because the entire WHERE clause condition is not enclosed within the parentheses.
C. It would execute and the output would display the desired result.
Question #6 Topic 2
View the exhibit and examine the structure of the STORES table.
STORES table -
Name Null? Type
----------------- ----- -------------
STORE_ID NUMBER
NAME VARCHAR2(100)
ADDRESS VARCHAR2(200)
CITY VARCHAR2(100)
COUNTRY VARCHAR2(100)
START_DATE DATE
END_DATE DATE
PROPERTY_PRICE NUMBER
You want to display the NAME of the store along with the ADDRESS, START_DATE, PROPERTY_PRICE, and the projected property price, which is
115% of property price.
The stores displayed must have START_DATE in the range of 36 months starting from 01-Jan-2000 and above.
Which SQL statement would get the desired output?
A. SELECT name, concat (address| | ','| |city| |', ', country) AS full_address, start_date, property_price, property_price*115/100 FROM stores
WHERE MONTHS_BETWEEN (start_date, '01-JAN-2000') <=36;
B. SELECT name, concat (address| | ','| |city| |', ', country) AS full_address, start_date, property_price, property_price*115/100 FROM stores
WHERE TO_NUMBER(start_date-TO_DATE('01-JAN-2000','DD-MON-RRRR')) <=36;
C. SELECT name, address||','||city||','||country AS full_address, start_date, property_price, property_price*115/100 FROM stores WHERE
MONTHS_BETWEEN (start_date, TO_DATE('01-JAN-2000','DD-MON-RRRR')) <=36;
D. SELECT name, concat (address||','| |city| |', ', country) AS full_address, start_date, property_price, property_price*115/100 FROM stores
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 156/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Question #7 Topic 2
B. When the BOOKS table is dropped, all the rows in the BOOK_TRANSACTIONS table are deleted but the table structure is retained.
C. When a row in the BOOKS table is deleted, the rows in the BOOK_TRANSACTIONS table whose BOOK_ID matches that of the deleted row
in the BOOKS table are also deleted.
D. When a value in the BOOKS.BOOK_ID column is deleted, the corresponding value is updated in the BOOKS_TRANSACTIONS.BOOK_ID
column.
Question #8 Topic 2
A. SELECT e.last_name, m.manager_id FROM employees e RIGHT OUTER JOIN employees m on (e.manager_id = m.employee_id) AND
e.employee_id = 123;
B. SELECT e.last_name, m.manager_id FROM employees e RIGHT OUTER JOIN employees m on (e.employee_id = m.manager_id) WHERE
e.employee_id = 123;
C. SELECT e.last_name, e.manager_id FROM employees e RIGHT OUTER JOIN employees m on (e.employee_id = m.employee_id) WHERE
e.employee_id = 123;
D. SELECT m.last_name, e.manager_id FROM employees e LEFT OUTER JOIN employees m on (e.manager_id = m.manager_id) WHERE
e.employee_id = 123;
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 157/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Question #9 Topic 2
Sales data of a company is stored in two tables, SALES1 and SALES2, with some data being duplicated across the tables. You want to display
the results from the table, which are not present in the SALES2 table.
SALES1 -
SALES1 table -
Name Null Type
------------------ ------------- ----------------
SALES_ID NUMBER
STORE_ID NUMBER
ITEMS_ID NUMBER
QUANTITY NUMBER
SALES_DATE DATE
SALES2 table -
Name Null Type
---------------- ------------- -----------------
SALES_ID NUMBER
STORE_ID NUMBER
ITEMS_ID NUMBER
QUANTITY NUMBER
SALES_DATE DATE
Which set operator generates the required output?
A. INTERSECT
B. UNION
C. PLUS
D. MINUS
E. SUBTRACT
A. SELECT last_name, city FROM members WHERE state ='MO' AND state ='MI';
D. SELECT DISTINCT last_name, city FROM members WHERE state ='MO' OR state ='MI';
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 158/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
B. SELECT member_id 'MEMBER ID', due_date 'DUE DATE', '$2 AS LATE FEE' FROM BOOKS_TRANSACTIONS;
C. SELECT member_id AS "MEMBER ID", due_date AS "DUE DATE", '$2' AS "LATE FEE" FROM BOOKS_TRANSACTIONS;
D. SELECT member_id AS "MEMBER ID", due_date AS "DUE DATE", $2 AS "LATE FEE" FROM BOOKS_TRANSACTIONS;
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 159/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit and examine the data in ORDERS_MASTER and MONTHLY_ORDERS tables.
ORDERS_MASTER -
ORDER_ID -
ORDER_TOTAL -
1000
2000
3000
MONTHLY_ORDERS -
ORDER_ID -
ORDER_TOTAL -
2500
Evaluate the following MERGE statement:
MERGE_INTO orders_master o -
USING monthly_orders m -
ON (o.order_id = m.order_id)
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 160/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
FROM product_information -
WHERE product_status = 'obsolete';
You received the following error while executing the above query:
ERROR -
ORA-01756: quoted string not properly terminated
What would you do to execute the query successfully?
A. Use Quote (q) operator and delimiter to allow the use of single quotation mark in the literal character string.
B. Enclose the literal character string in the SELECT clause within the double quotation marks.
C. Do not enclose the character literal string in the SELECT clause within the single quotation marks.
D. Use escape character to negate the single quotation mark inside the literal character string in the SELECT clause.
ORDERS -
Name -
Null?
Type -
ORDER ID -
NOT NULL -
NUMBER(4)
ORDATE DATE -
DATE -
CUSTOMER ID -
NUMBER(3)
ORDER TOTAL -
NUMBER(7,2)
The ORDERS table contains data and all orders have been assigned a customer ID. Which statement would add a NOT NULL constraint to the
CUSTOMER_ID column?
C. ALTER TABLE orders MODIFY customer_id CONSTRAINT orders_cust_nn NOT NULL (customer_id);
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 161/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
The user SCOTT who is the owner of ORDERS and ORDER_ITEMS tables issues the following GRANT command:
GRANT ALL -
ON orders, order_items -
TO PUBLIC;
What correction needs to be done to the above statement?
D. Separate GRANT statements are required for ORDERS and ORDER_ITEMS tables.
You want to display the date for the first Monday of the next month and issue the following command:
SQL>SELECT TO_CHAR(NEXT_DAY(LAST_DAY(SYSDATE), 'MON'),
'dd "is the first Monday for" fmmonth rrrr')
FROM DUAL;
What is the outcome?
E. In generates an error because fm and double quotation marks should not be used in the format string.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 162/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. SELECT d.department_id, c.course_id FROM department_details d RIGHT OUTER JOIN course_details c ON (d.department_id=c.
department_id);
B. SELECT d.department_id, c.course_id FROM department_details d LEFT OUTER JOIN course_details c ON (d.department_id=c.
department_id);
C. SELECT d.department_id, c.course_id FROM course_details c LEFT OUTER JOIN department_details d ON (c.department_id=d.
department_id);
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 163/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit for the structure of the STUDENT and FACULTY tables.
STUDENT -
Name Null? Type
------------------ ------------------- -------------
STUDENT_ID NOT NULL NUMBER(2)
STUDENT_NAME VARCHAR2(20)
FACULTY_ID VARCHAR2(2)
LOCATION_ID NUMBER(2)
FACULTY -
Name Null? Type
------------------ ------------------- -------------
FACULTY_ID NOT NULL NUMBER(2)
FACULTY_NAME VARCHAR2(20)
LOCATION_ID NUMBER(2)
You need to display the faculty name followed by the number of students handled by the faculty at the base location.
Examine the following two SQL statements:
Statement 1 -
SQL>SELECT faculty_name, COUNT(student_id)
Statement 2 -
SQL>SELECT faculty_name, COUNT(student_id)
FROM student NATURAL JOIN faculty
GROUP BY faculty_name;
Which statement is true regarding the outcome?
D. Both statements 1 and 2 execute successfully and give the same required result.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 164/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
View the exhibit and examine the structure of ORDERS and CUSTOMERS tables.
ORDERS -
Name -
Null?
Type -
ORDER_ID -
NOT NULL -
NUMBER(4)
ORDER_DATE -
NOT NULL -
DATE -
ORDER_MODE -
VARCHAR2(8)
CUSTOMER_ID -
NOT NULL -
NUMBER(6)
ORDER_TOTAL -
NUMBER(8, 2)
CUSTOMERS -
Name -
Null?
Type -
CUSTOMER_ID -
NOT NULL -
NUMBER(6)
CUST_FIRST_NAME -
NOT NULL -
VARCHAR2(20)
CUST_LAST_NAME -
NOT NULL -
VARCHAR2(20)
CREDIT_LIMIT -
NUMBER(9,2)
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 165/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
CUST_ADDRESS -
VARCHAR2(40)
Which INSERT statement should be used to add a row into the ORDERS table for the customer whose CUST_LAST_NAME is Roberts and
CREDIT_LIMIT is 600?
Assume there exists only one row with CUST_LAST_NAME as Roberts and CREDIT_LIMIT as 600.
A. INSERT INTO (SELECT o.order_id, o.order_date, o.order_mode, c.customer_id, o.order_total FROM orders o, customers c WHERE
o.customer_id = c.customer_id AND c.cust_last_name='Roberts' AND c.credit_limit=600) VALUES (1,'10-mar-2007', 'direct', (SELECT
customer_id FROM customers WHERE cust_last_name='Roberts' AND credit_limit=600), 1000);
B. INSERT INTO orders (order_id, order_date, order_mode, (SELECT customer id FROM customers WHERE cust_last_name='Roberts' AND
credit_limit=600), order_total); VALUES (1,'10-mar-2007', 'direct', &customer_id, 1000);
C. INSERT INTO orders VALUES (1,'10-mar-2007', 'direct', (SELECT customer_id FROM customers WHERE cust_last_name='Roberts' AND
credit_limit=600), 1000);
D. INSERT INTO orders (order_id, order_date, order_mode, (SELECT customer_id FROM customers WHERE cust_last_name='Roberts' AND
credit_limit=600), order_total);
The following are the steps for a correlated subquery, listed in random order:
1. The WHERE clause of the outer query is evaluated.
2. The candidate row is fetched from the table specified in the outer query.
3. The procedure is repeated for the subsequent rows of the table, till all the rows are processed.
4. Rows are returned by the inner query, after being evaluated with the value from the candidate row in the outer query.
Identify the option that contains the steps in the correct sequence in which the Oracle server evaluates a correlated subquery.
A. 2, 1, 4, 3
B. 4, 1, 2, 3
C. 4, 2, 1, 3
D. 2, 4, 1, 3
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 166/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Evaluate the following SELECT statement and view the exhibit to examine its output:
SELECT constraint_name, constraint_type, search_condition, r_constraint_name, delete_rule, status,
FROM user_constraints -
WHERE table_name = 'ORDERS';
CONSTRAINT_NAME -
CON SEARCH_CONDITI -
R_CONSTRAINT_NAME DELETE_RULE STATUS
ON -
ORDER_DATE_NN -
"ORDER_DATE" IS
ENABLED -
NOT NULL -
ORDER_CUSTOMER_ID_
C-
"CUSTOMER_ID" IS
ENABLED -
NN -
NOT NULL -
ORDER_MODE_LOV -
C-
order _mode in
ENABLED -
('direct',
'online')
C-
order total >= 0
ENABLED -
ORDER PK -
P-
ENABLED -
ORDERS CUSTOMER ID R -
CUSTOMERS ID -
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 167/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
SET NULL -
ENABLED -
R-
EMP EMP ID -
SET NULL -
ENABLED -
Which two statements are true about the output? (Choose two.)
A. The R_CONSTRAINT_NAME column gives the alternative name for the constraint.
D. The column DELETE_RULE decides the state of the related rows in the child table when the corresponding row is deleted from the parent
table.
Which two statements are true about sequences created in a single instance Oracle database? (Choose two.)
A. When the MAXVALUE limit for a sequence is reached, it can be increased by using the ALTER SEQUENCE statement.
C. The numbers generated by an explicitly defined sequence can only be used to insert data in one table.
D. CURRVAL is used to refer to the most recent sequence number that has been generated for a particular sequence.
E. When a database instance shuts down abnormally, sequence numbers that have been cached but not used are available again when the
instance is restarted.
Which two statements are true regarding the UNION and UNION ALL operators? (Choose two.)
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 168/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which three actions can you perform on an existing table containing data? (Choose three.)
E. Define a default value that is automatically inserted into a column containing nulls
Which two statements are true about single-row functions? (Choose two.)
B. FLOOR: returns the smallest integer greater than or equal to a specified number
Which three statements are true about sequences in a single instance Oracle database? (Choose three.)
B. A sequence's unallocated cached value are lost if the instance shuts down
D. Two or more tables cannot have keys generated from the same sequence
F. A sequence number that was allocated can be rolled back if a transaction fails
Which two statements are true about the SET VERIFY ON command? (Choose two.)
B. It displays values for variables used only in the WHERE clause of a query
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 169/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements are true about the rules of precedence for operators? (Choose two.)
A. The concatenation operator | | is always evaluated before addition and subtraction in an expression
B. Multiple parentheses can be used to override the default precedence of operators in an expression
C. Arithmetic operators with equal precedence area evaluated from left to right within an expression
E. The + binary operator has the highest precedence in an expression in a SQL statement
Which four statements are true regarding primary and foreign key constraints and the effect they can have on table data? (Choose four.)
A. It is possible for child rows that have a foreign key to remain in the child table at the time the parent row is deleted
B. Only the primary key can be defined at the column and table level
C. The foreign key columns and parent table primary key columns must have the same names
D. A table can have only one primary key and one foreign key
E. A table can have only one primary key but multiple foreign keys
F. Primary key and foreign key constraints can be defined at both the column and table level
G. It is possible for child rows that have a foreign key to be deleted automatically from the child table at the time the parent row is deleted
Which three are true about system and object privileges? (Choose three.)
A. WITH GRANT OPTION can be used when granting an object privilege to both users and roles
B. Adding a primary key constraint to an existing table in another schema requires a system privilege
C. Adding a foreign key constraint pointing to a table in another schema requires the REFERENCES object privilege
D. Revoking a system privilege that was granted with WITH ADMIN OPTION has a cascading effect
E. Revoking an object privilege that was granted with the WITH GRANT OPTION clause has a cascading effect.
F. WITH GRANT OPTION cannot be used when granting an object privilege to PUBLIC
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 170/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements are true about selecting related rows from two tables based on an Entity Relationship Diagram (ERD)? (Choose two.)
A. Implementing a relationship between two tables might require joining additional tables
B. Relating data from a table with data from the same table is implemented with a self join
D. Every relationship between the two tables must be implemented in a join condition
Which two statements are true about substitution variables? (Choose two.)
B. A substitution variable used to prompt for a column name must be enclosed in a single quotation marks
C. A substitution variable prefixed with & always prompts only once for a value in a session
E. A substitution variable used to prompt for a column name must be enclosed in double quotation marks
F. A substitution variable prefixed with && prompts only once for a value in a session unless it is set to undefined in the session
Which three statements are true about inner and outer joins? (Choose three.)
F. Outer joins can be used when there are multiple join conditions on two tables
Which three statements are true about the DESCRIBE command? (Choose three.)
C. It displays the PRIMARY KEY constraint for any column or columns that have that constraint
F. It displays the NOT NULL constraint for any columns that have that constraint
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 171/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. SELECT REPLACE (TRIM(TRAILING "˜son' FROM cust_last_name), "˜An', "˜O') FROM customers;
Which three statements are true about performing Data Manipulation Language (DML) operations on a view with no INSTEAD OF triggers
defined? (Choose three.)
B. Views cannot be used to add rows to an underlying table if the table has columns with NOT NULL constraints lacking default values which
are not referenced in the defining query of the view.
C. Views cannot be used to query rows from an underlying table if the table has a PRIMARY KEY and the PRIMARY KEY columns are not
referenced in the defining query of the view.
E. The WITH CHECK clause has no effect when deleting rows from the underlying table through the view.
F. Views cannot be used to add or modify rows in an underlying table if the defining query of the view contains the DISTINCT keyword.
An Oracle database server session has an uncommitted transaction in progress which updated 5000 rows in a table.
In which three situations does the transactions complete thereby committing the updates? (Choose three.)
A. when a DBA issues a successful SHUTDOWN TRANSACTIONAL statement and the user then issues a COMMIT
C. when a COMMIT statement is issued by the same user from another session in the same database instance
E. when a DBA issues a successful SHUTDOWN IMMEDIATE statement and the user then issues a COMMIT
F. when a CREATE TABLE AS SELECT statement is executed unsuccessfully in the same session
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 172/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
The INVOICE table has a QTY_SOLD column of data type NUMBER and an INVOICE_DATE column of data type DATE.
NLS_DATE_FORMAT is set to DD-MON-RR.
Which two are true about data type conversions involving these columns in query expressions? (Choose two.)
The ORDERS table has a primary key constraint on the ORDER_ID column.
The ORDER_ITEMS table has a foreign key constraint on the ORDER_ID column, referencing the primary key of the ORDERS table.
The constraint is defined with ON DELETE CASCADE.
There are rows in the ORDERS table with an ORDER_TOTAL of less than 1000.
Which three DELETE statements execute successfully?
A. 16
B. 200
C. 100
D. 160
E. 150
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 173/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. A SELECT statement can access one or more indices without accessing any tables
C. A table belonging to one user can have an index that belongs to a different user
E. An update to a table can result in updates to any or all of the table's indexes
F. When a table is dropped and is moved to the RECYCLE BIN, all indexes built on that table are permanently dropped
Which three are true about the CREATE TABLE command? (Choose three.)
A. It can include the CREATE..INDEX statement for creating an index to enforce the primary key constraint
C. A user must have the CREATE ANY TABLE privilege to create tables
E. The owner of the table should have space quota available on the tablespace where the table is defined
F. The owner of the table must have the UNLIMITED TABLESPACE system privilege
st
You need to calculate the number of days from 1
January 2019 until today.
Dates are stored in the default format of DD-MON-RR.
Which two queries give the required output?
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 174/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which three actions can you perform by using the ORACLE_DATAPUMP access driver? (Choose three.)
A. Read data from an external table and load it into a table in the database
E. Read data from a table in the database and insert it into an external table
Which three statements are true about single-row functions? (Choose three.)
B. The data type returned can be different from the data type of the argument
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 175/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which three privileges can be restricted to a subset of columns in a table? (Choose three.)
A. ALTER
B. DELETE
C. UPDATE
D. SELECT
E. INDEX
F. REFERENCES
G. INSERT
B. A new column with the name DEPARTMENT_ID can be added to the EMPLOYEES table.
D. The DEPARTMENT_ID column is set to null for all rows in the table.
F. The storage space occupied by the DEPARTMENT_ID column is released only after a COMMIT is issued.
D. TIMESTAMP
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 176/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
E. WHERE order_date IN (TO_DATE('OCT 21 2018', 'Mon DD YYYY'), TO_CHAR('Nov 21 2018', 'Mon DD YYYY'))
A. After issuing a savepoints, you can roll back to the savepoint name within the current transaction.
B. A ROLLBACK TO SAVEPOINT command issued before the start of a transaction results in an error.
C. They make uncommitted updates visible to other sessions owned by the same user.
D. After issuing a savepoint, you cannot roll back the complete transaction.
E. You can commit updates done between two savepoints without committing other updates in the current transaction.
The SYSDATE function displays the current Oracle Server date as:
21-MAY-19
You wish to display the date as:
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 177/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two are true about scalar subquery expressions? (Choose two.)
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 178/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. COMMIT erases all the transaction's savepoints and releases its locks.
B. ROLLBACK TO SAVEPOINT undoes the transaction's changes made since the named savepoint and then ends the transaction.
C. COMMIT ends the transaction and makes all its changes permanent.
D. ROLLBACK without the TO SAVEPOINT clause undoes all the transaction's changes but does not erase its savepoints.
E. ROLLBACK without the TO SAVEPOINT clause undoes all the transaction's changes but does not release its locks.
F. ROLLBACK without the TO SAVEPOINT clause undoes all the transaction's changes, releases its locks and erases its savepoints.
Which three are key components of an Entity Relationship Model? (Choose three.)
A. an activity
B. a table
C. a relationship
D. an attribute
E. a unique identifier
F. an entity
Which two are true about external tables that use the ORACLE_DATAPUMP access driver? (Choose two.)
A. When creating an external table, data can be selected from another external table or from a table whose rows are stored in database
blocks.
B. Creating an external table creates a dump file that can be used only by an external table in the same database.
C. When creating an external table, data can be selected only from a table whose rows are stored in database blocks.
E. Creating an external table creates a dump file that can be used by an external table in the same or a different database.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 179/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which three statements are true about external tables? (Choose three.)
D. Object privileges granted on a table automatically apply to all synonyms for that table.
E. Only users with the GRANT ANY PRIVILEGE privilege can grant and revoke system privileges from other users.
F. Schema owners can grant any object privilege on any object in their schema to any other user or role.
E. A role is named group of related privileges that can only be assigned to a user.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 180/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements are true about an Oracle database? (Choose two.)
A. The DELETE command will wait for HR'S transaction to end then delete the row.
D. The DELETE command will wait for HR'S transaction to end then return an error.
Which two statements are true about the data dictionary? (Choose two.)
A. Views with the prefix ALL_, DBA_ and USER_ are not all available for every type of metadata.
B. Views with the prefix ALL_ display metadata for objects to which the current user has access.
C. Views with the prefix DBA_ display only metadata for objects in the SYS schema.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 181/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
Which two statements are true about dropping views? (Choose two.)
A. Data selected by a view's defining query is deleted from its underlying tables when the view is dropped.
C. The creator of a view to be dropped must have the DROP ANY VIEW privilege.
D. CASCADE CONSTRAINTS must be specified when referential integrity constraints on other objects refer to primary or unique keys in the
view to be dropped.
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 182/183
31.07.2022, 12:14 1z0-071 Exam – Free Actual Q&As, Page 1 | ExamTopics
A. A table can have only one PRIMARY KEY but may have multiple FOREIGN KEY constraints.
B. A table can have multiple PRIMARY KEY and multiple FOREIGN KEY constraints.
C. PRIMARY KEY and FOREIGN KEY constraints can be specified at the column and at the table level.
D. NOT NULL can be specified at the column and at the table level.
E. A FOREIGN KEY column in a child table and the referenced PRIMARY KEY column in the parent table must have the same names.
F. A table can have only one PRIMARY KEY and one FOREIGN KEY constraint.
Which three statements are true about multiple row subqueries? (Choose three.)
https://www.examtopics.com/exams/oracle/1z0-071/custom-view/ 183/183