Exam Code | 1z0-071 |
Exam Name | Oracle Database 12c SQL |
Questions | 318 Questions Answers With Explanation |
Update Date | July 11,2024 |
Price |
Was : |
Table EMPLOYEES contains columns including EMPLOYEE_ID, JOB_ID and SALARY.Only the EMPLOYEE_ID column is indexed.Rows exist for employees 100 and 200.Examine this statement:Which two statements are true? (Choose two.)
A. Employees 100 and 200 will have the same JOB_ID as before the update command
B. Employees 100 will have JOB_ID set to the same value as the JOB_ID of employee 200
C. Employees 100 and 200 will have the same SALARY as before the update command
D. Employee 200 will have SALARY set to the same value as the SALARY of employee 100
E. Employee 100 will have SALARY set to the same value as the SALARY of employee 200
F. Employee 200 will have JOB_ID set to the same value as the JOB_ID of employee 100
Which three statements are true about single-row functions? (Choose three.)
A. They can be nested to any level
B. The data type returned can be different from the data type of the argument
C. They can accept only one argument
D. The argument can be a column name, variable, literal or an expression
E. They can be used only in the WHERE clause of a SELECT statement
F. They return a single result row per table
The ORDERS table a primary key constrain 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 CASCADS.There are rows in the ORDERS table with an ORDER_TOTAL of less than 1000.Which three DELETE statements execute successfully?
A. DELETE * FROM orders WHERE order_total < 1000;
B. DELETE FROM orders;
C. DELETE order_id FROM orders WHERE order_total < 1000;
D. DELETE orders WHERE order_total < 1000;
E. DELETE FROM orders WHERE order_total < 1000;
Which two statements are true about views?
A. Views can be updated without the need to re-grant privileges on the view.
B. Views can be indexed.
C. The with check clause prevents certain rows from being displayed when querying the view.
D. The with check clause prevents certain rows from being updated or inserted in the underlying table through the view.
E. Tables in the defining query of a view must always exist in order to create the view.
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
B. It implicitly executes a commit
C. A user must have the CREATE ANY TABLE privilege to create tables
D. It implicitly rolls back any pending transactions
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
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
C. Rows from unrelated tables cannot be joined
D. Every relationship between the two tables must be implemented in a join condition
E. An inner join relates rows within the same table
Which two statements are true about external tables?
A. Their data can be retrieved by using only SQL or PL/SQL.
B. Their metadata and actual data are both stoned outside the database.
C. Indexes can be created on them.
D. You can populate them from existing data in the database by using the CREATE TABLE AS SELECT command.
E. DML statements cannot be used on them.
Examine the description of the PRODUCTS table:Which three queries use valid expressions? (Choose three.)
A. SELECT product_id, (expiry_date – delivery_date) * 2 FROM products;
B. SELECT product_id, unit_price | | 5 “Discount”, unit_price + surcharge – discount FROM products;
C. SELECT product_id, unit_price, 5 “Discount”, unit_price + surcharge – discount FROM products;
D. SELECT product_id, unit_price, unit_price + surcharge FROM products;
E. SELECT product_id, (unit_price * 0.15 / (4.75 + 552.25)) FROM products;
F. SELECT product_id, expiry_date * 2 FROM products;
Which three statements are true regarding indexes? (Choose three.)
A. A SELECT statement can access one or more indices without accessing any tables
B. An update to a table can result in no updates to any of the table’s indexes
C. A table belonging to one user can have an index that belongs to a different user
D. A UNIQUE index can be altered to be non-unique
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
View the Exhibits and examine the structure of the costs and promotions tables.You want to display prod_ids whose promotion cost is less than the highest cost PR0D_ID in a promotion time interval.Examine this SQL statement:What will be the result?
A. It gives an error because the ROUP BY clause is not valid.
B. It executes successfully and gives the required result.
C. It gives an error because the all keyword is not valid.
D. It executes successfully but does not give the required result.