exam questions

Exam 1z0-061 All Questions

View all questions & answers for the 1z0-061 exam

Exam 1z0-061 topic 4 question 62 discussion

Actual exam question from Oracle's 1z0-061
Question #: 62
Topic #: 4
[All 1z0-061 Questions]

Examine the structure of the TRANSACTIONS table:

Name Null Type -
TRANS_ID NOT NULL NUMBER(3)
CUST_NAME VARCHAR2(30)

TRANS_DATE DATE -
TRANS_AMT NUMBER(10, 2)
You want to display the transaction date and specify whether it is a weekday or weekend.
Evaluate the following two queries:

Which statement is true regarding the above queries?

  • A. Both give wrong results.
  • B. Both give the correct result.
  • C. Only the first query gives the correct result.
  • D. Only the second query gives the correct result.
Show Suggested Answer Hide Answer
Suggested Answer: C 🗳️
Range Conditions Using the BETWEEN Operator
Use the BETWEEN operator to display rows based on a range of values:

SELECT last_name, salary -

FROM employees -
WHERE salary BETWEEN 2500 AND 3500;
Range Conditions Using the BETWEEN Operator
You can display rows based on a range of values using the BETWEEN operator. The range that you specify contains a lower limit and an upper limit.
The SELECT statement in the slide returns rows from the EMPLOYEES table for any employee whose salary is between $2, 500 and $3, 500.
Values that are specified with the BETWEEN operator are inclusive. However, you must specify the lower limit first.
You can also use the BETWEEN operator on character values:

SELECT last_name -

FROM employees -
WHERE last_name BETWEEN 'King' AND 'Smith';

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
Currently there are no comments in this discussion, be the first to comment!
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...