It is more faster and easier to pass the 1z0 061 dumps by using 1z0 061 pdf. Immediate access to the 1z0 061 pdf and find the same core area 1z0 061 pdf with professionally verified answers, then PASS your exam with a high score now.
Online Oracle 1Z0-061 free dumps demo Below:
NEW QUESTION 1
Examine the structure of the EMPLOYEES and NEW_EMPLOYEES tables:
Which DELETE statement is valid?
Answer: C
NEW QUESTION 2
You create a sequence as follows: create sequence seq1 start with 1;
After selecting from it a few times, you want to reinitialize it to reissue the numbers already generated.
How can you do this?
Answer: A
Explanation: It is not possible to change the next value of a sequence, so you must re-create it.
NEW QUESTION 3
This statement will fail:
create unique bitmap index on employees(department_id,hire_date); Why?
Answer: A
NEW QUESTION 4
Which statement adds a constraint that ensures the CUSTOMER_NAME column of the CUSTOMERS table holds a value?
Answer: C
NEW QUESTION 5
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? (Choose two.)
Answer: DE
Explanation: Describe the Types of Problems That the Subqueries Can Solve
There are many situations where you will need the result of one query as the input for another.
Use of a Subquery Result Set for Comparison Purposes
Which employees have a salary that is less than the average salary? This could be answered by two statements, or by a single statement with a subquery. The following example uses two statements:
select avg(salary) from employees;
select last_name from employees where salary < result_of_previous_query ; Alternatively, this example uses one statement with a subquery:
select last_name from employees where salary < (select avg(salary)from employees);
In this example, the subquery is used to substitute a value into the WHERE clause of the parent query: it is returning a single value, used for comparison with the rows retrieved by
the parent query.
The subquery could return a set of rows. For example, you could use the following to find all departments that do actually have one or more employees assigned to them:
select department_name from departments where department_id in (select distinct(department_id) from employees);
NEW QUESTION 6
Examine the structure of the SHIPMENTS table:
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:
Which statement is true regarding the above commands?
Answer: C
Explanation: The MONTHS_BETWEEN(date 1, date 2) function returns the number of months between two dates:
months_between('01-FEB-2008', '01-JAN-2008') = 1 The DECODE Function
Although its name sounds mysterious, this function is straightforward. The DECODE function implements if then-else conditional logic by testing its first two terms for equality and returns the third if they are equal and optionally returns another term if they are not. DECODE Function Facilitates conditional inquiries by doing the work of a CASE expression or an IF-THENELSE statement:
DECODE(col|expression, search1, result1 [, search2, result2, ..., ]
[, default]) DECODE Function
The DECODE function decodes an expression in a way similar to the IF-THEN-ELSE logic that is used in various languages. The DECODE function decodes expression after comparing it to each search value. If the expression is the same as search, result is returned.
If the default value is omitted, a null value is returned where a search value does not match any of the result values.
NEW QUESTION 7
See the structure of the PROGRAMS table:
Which two SQL statements would execute successfully? (Choose two.)
Answer: AD
Explanation: NVL Function
Converts a null value to an actual value:
Data types that can be used are date, character, and number. Data types must match:
– NVL(commission_pct, 0)
– NVL(hire_date, '01-JAN-97')
– NVL(job_id, 'No Job Yet')
MONTHS_BETWEEN(date1, date2): Finds the number of months between date1 and date2
The result can be positive or negative. If date1 is later than date2, the result is positive; if date1 is earlier than date2, the result is negative. The noninteger part of the result represents a portion of the month.
MONTHS_BETWEEN returns a numeric value. - answer C NVL has different datatypes - numeric and strings, which is not possible!
The data types of the original and if null parameters must always be compatible. They must either be of the same type, or it must be possible to implicitly convert if null to the type of the original parameter. The NVL function returns a value with the same data type as the original parameter.
NEW QUESTION 8
Examine the structure of the EMPLOYEES and NEW_EMPLOYEES tables:
EMPLOYEES
EMPLOYEE_ID NUMBER Primary Key FIRST_NAME VARCHAR2(25) LAST_NAME VARCHAR2(25) HIRE_DATE DATE
NEW_EMPLOYEES
EMPLOYEE_ID NUMBER Primary Key NAME VARCHAR2(60)
Which MERGE statement is valid?
Answer: A
Explanation: The correct statement for MERGE is MERGE INTO table_name
Incorrect
B- Wrong statement with the keyword EXISTS
C- Wrong statement with the keyword EXISTS
D- Wrong statement on the MERGE new_employees
Refer: Introduction to Oracle9i: SQL, Oracle University Study Guide, 8-29
NEW QUESTION 9
You work as a database administrator at ABC.com. You study the exhibit carefully. Exhibit
Using the PROMOTIONS table, you need to display the names of all promos done after January 1, 2001 starting with the latest promo.
Which query would give the required result? (Choose all that apply.)
Answer: BC
NEW QUESTION 10
You work as a database administrator at ABC.com. You study the exhibit carefully and examine the structure of CUSTOMRS AND SALES tables.
Evaluate the following SQL statement: Exhibit:
Which statement is true regarding the execution of the above UPDATE statement?
Answer: A
NEW QUESTION 11
You are granted the CREATE VIEW privilege. What does this allow you to do?
Answer: C
Explanation: You can create a view in your own schema only if you are granted the CREATE VIEW privilege.
Incorrect Answers
A:. You can create a view in your own schema only.
B:. You can create a view in your own schema only, not in any schema. D:. There is no sequence view in Oracle.
E:. You cannot create a view that is accessible by everyone. You will need specially grant SELECT privileges on this view for everyone.
F:. You can create a view in your own schema, but not only for tables in your schema. You can use object from other users schemas if you have privileges to retrieve data from them.
OCP Introduction to Oracle 9i: SQL Exam Guide, Jason Couchman, p. 292-301 Chapter 7: Creating Other Database Objects in Oracle
NEW QUESTION 12
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?
Answer: C
Explanation: Using the TO_CHAR Function with Dates
TO_CHAR converts a datetime data type to a value of VARCHAR2 data type in the format specified by the format_model. A format model is a character literal that describes the format of datetime stored in a character string. For example, the datetime format model for
the string '11-Nov-1999' is 'DD-Mon-YYYY'. You can use the
TO_CHAR function to convert a date from its default format to the one that you specify. Guidelines
• The format model must be enclosed with single quotation marks and is case-sensitive.
• The format model can include any valid date format element. But be sure to separate the date value from the format model with a comma.
• The names of days and months in the output are automatically padded with blanks.
• To remove padded blanks or to suppress leading zeros, use the fill mode fm element.
Elements of the Date Format Model
---------------------------------------------------------------------
DY Three-letter abbreviation of the day of the week DAY Full name of the day of the week
DD Numeric day of the month
MM Two-digit value for the month
MON Three-letter abbreviation of the month MONTH Full name of the month
YYYY Full year in numbers
YEAR Year spelled out (in English)
NEW QUESTION 13
In the customers table, the CUST_CITY column contains the value 'Paris' for the CUST_FIRST_NAME 'Abigail'.
Evaluate the following query:
What would be the outcome?
Answer: B
NEW QUESTION 14
View the Exhibit and examine the structure of CUSTOMERS and SALES tables.
Evaluate the following SQL statement:
UPDATE (SELECT prod_id, cust_id, quantity_sold, time_id FROM sales)
SET time_id = '22-MAR-2007'
WHERE cust_id = (SELECT cust_id
FROM customers
WHERE cust_last_name = 'Roberts' AND credit_limit = 600);
Which statement is true regarding the execution of the above UPDATE statement?
Answer: C
Explanation: One UPDATE statement can change rows in only one table, but it can change any number of rows in that table.
NEW QUESTION 15
View the Exhibit and examine the data in the PROMO_CATEGORY and PROMO_COST columns of the PROMOTIONS table.
Evaluate the following two queries:
SQL>SELECT DISTINCT promo_category to_char(promo_cost)"code" FROM promotions ORDER BY code;
SQL>SELECT DISTINCT promo_category promo_cost "code" FROM promotions ORDER BY 1;
Which statement is true regarding the execution of the above queries?
Answer: B
NEW QUESTION 16
Evaluate these two SQL statements:
SELECT last_name, salary, hire_date FROM EMPLOYEES ORDER BY salary DESC; SELECT last_name, salary, hire_date FROM EMPLOYEES ORDER BY 2 DESC;
What is true about them?
Answer: A
Explanation: the two statement produce identical results as ORDER BY 2 will take the second column as sorting column.
Incorrect
B- there is no syntax error
C- result are sorted in ascending order by default
D- ORDER BY 2 will take the second column as sorting column.
Refer: Introduction to Oracle9i: SQL, Oracle University Study Guide, 2-22
NEW QUESTION 17
Which two statements are true regarding savepoints? (Choose two.)
Answer: BC
NEW QUESTION 18
You need to create a table named ORDERS that contain four columns:
1. AN ORDER_ID column of number data type
2. A CUSTOMER_ID column of number data type
3. AN ORDER_STATUS column that contains a character data type
4. A DATE_ORDERED column to contain the date the order was placed.
When a row is inserted into the table, if no value is provided when the order was placed, today’s date should be used instead.
Which statement accomplishes this?
Answer: B
Explanation: Requirement that Order_Status should be a character data type
Not E: Order_status must be a character data type. There is also a syntax error.
NEW QUESTION 19
Evaluate the following SQL statement:
SQL> SELECT cust_id, cust_last_name "Last Name" FROM customers
WHERE country_id = 10 UNION
SELECT cust_id CUST_NO, cust_last_name
FROM customers WHERE country_id = 30;
Which ORDER BY clause are valid for the above query? (Choose all that apply.)
Answer: AC
Explanation: Using the ORDER BY Clause in Set Operations
- The ORDER BY clause can appear only once at the end of the compound query.
- Component queries cannot have individual ORDER BY clauses.
- The ORDER BY clause recognizes only the columns of the first SELECT query.
- By default, the first column of the first SELECT query is used to sort the output in an ascending order.
P.S. Easily pass 1Z0-061 Exam with 339 Q&As 2passeasy Dumps & pdf Version, Welcome to Download the Newest 2passeasy 1Z0-061 Dumps: https://www.2passeasy.com/dumps/1Z0-061/ (339 New Questions)