Free Oracle 1Z0-071 Exam Questions (page: 12)

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.

Which statement is true regarding this SQL statement?

  1. It executes successfully and generates the required result.
  2. It produces an error because COUNT (*) should be specified in the SELECT clause also.
  3. It produces an error because COUNT (*) should be only in the HAVING clause and not in the WHERE clause.
  4. It executes successfully but produces no result because COUNT (prod_id) should be used instead of COUNT (*).

Answer(s): C



The customers table has the following structure:

You need to write a query that does the following tasks:

1. Display the first name and tax amount of the customers. Tax is 5% of their credit limit.
2. Only those customers whose income level has a value should be considered.
3. Customers whose tax amount is null should not be considered.

Which statement accomplishes all the required tasks?

  1. Option A
  2. Option B
  3. Option C
  4. Option D

Answer(s): B



View the Exhibit and examine the data in the PRODUCTS table.

Which statement would add a column called PRICE, which cannot contain NULL?

  1. ALTER TABLE products
    ADD price NUMBER(8,2) NOT NULL;
  2. ALTER TABLE products
    ADD price NUMBER(8,2) DEFAULT NOT NULL;
  3. ALTER TABLE products
    ADD price NUMBER(8,2) DEFAULT 0 NOT NULL;
  4. ALTER TABLE products
    ADD price NUMBER(8,2) DEFAULT CONSTRAINT p_nn NOT NULL.

Answer(s): C



Examine the structure and data in the PRICE_LIST table:

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?

  1. SELECT TO_CHAR (prod_price* .25, ‘$99,999.99’)
    FROM PRICE_LIST
  2. SELECT TO_CHAR (TO_NUMBER(prod_price) * .25, ‘$99,999.00’)
    FROM PRICE_LIST
  3. SELECT TO_CHAR (TO_NUMBER(prod_price, ‘$99,999.99’) * . 25, ‘$99,999.00’)
    FROM PRICE_LIST
  4. SELECT TO_NUMBER (TO_NUMBER(prod_price, ‘$99,999.99’) * . 25, ‘$99,999.00’)
    FROM PRICE_LIST

Answer(s): C



Examine the structure of the SHIPMENTS table:



You want to generate a report that displays the SHIPMENT_DATE is later than one month from Evaluate the following two queries:



PO_ID and the penalty amount to be paid if the the PO_DATE. The penalty is $20 per day.
Which statement is true regarding the above commands?

  1. Both execute successfully and give correct results.
  2. Only the first query executes successfully but gives a wrong result.
  3. Only the first query executes successfully and gives the correct result.
  4. Only the second query executes successfully but gives a wrong result.
  5. Only the second query executes successfully and gives the correct result.

Answer(s): C



Viewing page 12 of 77



Post your Comments and Discuss Oracle 1Z0-071 exam prep with other Community members:

1Z0-071 Exam Discussions & Posts