Pass the Oracle Oracle PL 1z0-071 Questions and answers with CertsForce

Viewing page 6 out of 10 pages
Viewing questions 51-60 out of questions
Questions # 51:

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?

Options:

A.

invoice_date> '01-02-2019': uses implicit conversion


B.

qty_sold ='05549821 ': requires explicit conversion


C.

CONCAT(qty_sold, invoice_date): requires explicit conversion


D.

qty_sold BETWEEN '101' AND '110': uses implicit conversion


E.

invoice_date = '15-march-2019': uses implicit conversion


Expert Solution
Questions # 52:

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


Expert Solution
Questions # 53:

Examine the description of the CUSTOMERS table:

Question # 53

You want to display details of all customers who reside in cities starting with the letter D followed by at least two character.

Which query can be used?

Options:

A.

SELECT * FROM customers WHERE city ='D_%';


B.

SELECT * FROM customers WHERE city ='%D_';


C.

SELECT * FROM customers WHERE city LIKE'D %';


D.

SELECT * FROM customers WHERE city LIKE'D_';


Expert Solution
Questions # 54:

Examine this statement:

SELECT 1 AS id, ' John' AS first name

FROM DUAL

UNION

SELECT 1 , ' John' AS name

FROM DUAL

ORDER BY 1;

What is returned upon execution?

Options:

A.

0 rows


B.

an error


C.

1 row


D.

2 rows


Expert Solution
Questions # 55:

Examine this statement:

CREATE TABTE orders

(sarial_no NUMBER UNIQUE,

order_id NUMBER PRIMARY KEY ,

order_date DATE NOT NULL,

status VARCHAR2 (10) CHECK (status IN ('CREDIT', 'CASH')),

product_id NUMBER REFERENCES products (product_id),

order_ total NUMBER);

On which two columns of the table will an index be created automatically?

Options:

A.

SERIAL_NO


B.

ORDER_DATE


C.

PRODUCT_ ID


D.

ORDER TOTAL


E.

ORDER_ ID


F.

STATUS


Expert Solution
Questions # 56:

Examine the description of the ORDER_ITEMS table:

Question # 56

Examine this incomplete query:

SELECT DISTINCT quantity * unit_price total_paid FROM order_items ORDER BY ;

Which two can replace so the query completes successfully?

Options:

A.

quantity


B.

quantity, unit_price


C.

total_paid


D.

product_id


E.

quantity * unit_price


Expert Solution
Questions # 57:

Examine these two queries and their output:

SELECT deptno, dname FROM dept;

Question # 57

SELECT ename, job, deptno FROM emp ORDER BY deptno;

Question # 57

Now examine this query:

SELECT ename, dname

FROM emp CROSS JOIN dept WHERE job = 'MANAGER'

AND dept.deptno IN (10, 20) ;

Options:

A.

64


B.

6


C.

3


D.

12


Expert Solution
Questions # 58:

Examine the description of the CUSTOMERS table:

Question # 58

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:

SELECT cust_last_nare, cust_credit_limit FROM customers

Which two WHERE conditions give the required result?

Options:

A.

WHERE UPPER(cust_last_name) IN ('A%', 'B%') AND cust_credit_limit < 1000:


B.

WHERE (INITCAP(cust_last_name) LIKE ‘A%' OR ITITCAP(cust_last_name) LIKE ‘B%') AND cust_credit_limit < 1000


C.

WHERE UPPER(cust_last_name) BETWEEN UPPER('A%' AND 'B%’) AND ROUND(cust_credit_limit) < 1000;


D.

WHERE (UPPER(cust_last_name) LIKE 'A%’ OR UPPER(cust_last_name) LIKE ‘B%’) AND ROUND(cust_credit_limit) < 1000;


E.

WHERE (UPPER(cust_last_name) like INITCAP ('A') OR UPPER(cust_last_name) like INITCAP('B')) AND ROUND(cust_credit_limit) < ROUND(1000) ;


Expert Solution
Questions # 59:

Which three items does a direction of a relationship contain?

Options:

A.

an attribute


B.

a cardinality


C.

label


D.

an optionality


E.

a unique identifier


F.

an entity


Expert Solution
Questions # 60:

Examine the description of the PROMOTIONS TABLE:

You want to display the unique is promotion costs in each promotion category.

Which two queries can be used?

Options:

A.

SELECT DISTINCT promo_category, promo_cost FROM promotions ORDER BY 1;


B.

SELECT promo_cost, promo_category FROM promotions ORDER BY 1


C.

SELECT promo_category, DISTINCT promo_cost FROM promotiong ORDER BY 2:


D.

select DISTINCT promo_categoryIl ‘has’||promol_cost as COSTS FROM promotions ORDER BY 1:


E.

SELECT DISTINCT promo_cost ||’in’IIDISTINCT promo_category promotions ORDER BY1:


Expert Solution
Viewing page 6 out of 10 pages
Viewing questions 51-60 out of questions