Labour Day Special - Limited Time 65% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: top65certs

Ace Your 1z0-071 Oracle PL Exam

Page: 7 / 24
Total 324 questions

Oracle Database 12c SQL Questions and Answers

Question 25

Which two are true about granting privilege on objects?

Options:

A.

The owner of an object acquires all object privilege on that object by default.

B.

The WITH GRANT OPTION clause can be used only by DBA users.

C.

A table owner must grant the references privilege to allow other users to create FOREIGN KEY constraints using that table.

D.

An object privilege can be granted to a role only by the owner of that object.

E.

An object privilege can be granted to other users only by the owner of object.

Question 26

Examine the description of the EMPLOYEES table:

Which query is valid?

Options:

A.

SELECT dept_id, join date, SUM(salary) FROM employees GROUP BY dept_id,join_date;

B.

SELECT dept_id, MAX (AVG(salary)) FROM employees GROUP BY dept_id;

C.

SELECT dept_id, AVG(NAX(salary)) FROM employees GROUP BY dept_id;

D.

SELECT dept_id, join_date, SUM(salary) FROM employees GROUP BY dept_id;

Question 27

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, I cust_id, order_date DEFAULT SYSDATE)

AS SELECT I prod_id,cust_id,time_id FROM sales.

Which statement is true regarding the above command?

Options:

A.

The NEW_SALES table would not get created because the DEFAULT value cannot be specified in the column definition.

B.

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.

C.

The NEW_SALES table would not get created because the column names in the CREATE TABLE command and the SELECT clause I 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

Question 28

Which two actions can you perform with object privileges?

Options:

A.

Create roles.

B.

Delete rows from tables in any schema except sys.

C.

Set default and temporary tablespaces for a user.

D.

Create FOREIGN KEY constraints that reference tables in other schemas.

E.

Execute a procedure or function in another schema.

Page: 7 / 24
Total 324 questions