exam questions

Exam 1z0-071 All Questions

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

Exam 1z0-071 topic 1 question 80 discussion

Actual exam question from Oracle's 1z0-071
Question #: 80
Topic #: 1
[All 1z0-071 Questions]

Which two are true about queries using set operators such as UNION? (Choose two.)

  • A. In a query containing multiple set operators, INTERSECT always takes precedence over UNION and UNION ALL.
  • B. An expression in the first SELECT list must have a column alias for the expression.
  • C. All set operators are valid on columns of all data types.
  • D. CHAR columns of different lengths used with a set operator return a VARCHAR2 whose length equals the longest char value.
  • E. Queries using set operators do not perform implicit conversion across data type groups (e.g. character, numeric).
Show Suggested Answer Hide Answer
Suggested Answer: DE 🗳️

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
Thameur01
2 weeks ago
Selected Answer: AD
A. In a query containing multiple set operators, INTERSECT always takes precedence over UNION and UNION ALL. Correct: In queries with multiple set operators, the precedence order is: INTERSECT UNION / UNION ALL MINUS If parentheses are not used to explicitly define precedence, INTERSECT is evaluated before UNION or UNION ALL. D. CHAR columns of different lengths used with a set operator return a VARCHAR2 whose length equals the longest char value. Correct: When CHAR columns of varying lengths are combined using a set operator, Oracle returns the result as a VARCHAR2 column whose length matches the longest CHAR value in the result set.
upvoted 1 times
...
acd3ea6
3 months, 2 weeks ago
Selected Answer: DE
https://docs.oracle.com/en/database/oracle/oracle-database/19/sqlrf/The-UNION-ALL-INTERSECT-MINUS-Operators.html#GUID-B64FE747-586E-4513-945F-80CB197125EE
upvoted 2 times
...
Bissto
4 months, 2 weeks ago
Selected Answer: AD
A. In a query containing multiple set operators, INTERSECT always takes precedence over UNION and UNION ALL. When multiple set operators are used in a query, INTERSECT has higher precedence than UNION and UNION ALL. This means that the INTERSECT operation will be evaluated before the other set operators, unless parentheses are used to explicitly define the order of operations. D. CHAR columns of different lengths used with a set operator return a VARCHAR2 whose length equals the longest char value. When CHAR columns of different lengths are combined using set operators, the result is a VARCHAR2 column with a length equal to the longest CHAR value in the result set. This is due to how Oracle handles the return type when different CHAR lengths are combined.
upvoted 1 times
...
yaya32
12 months ago
Selected Answer: DE
DE are correct
upvoted 3 times
...
lucemqy
1 year, 2 months ago
Selected Answer: DE
DE are the correct answer
upvoted 2 times
...
HassanMkhlalati
1 year, 4 months ago
Selected Answer: DE
DE are correct
upvoted 1 times
...
kuff
1 year, 8 months ago
Selected Answer: DE
DE are correct
upvoted 1 times
...
Orxan_H
1 year, 8 months ago
Selected Answer: DE
D E are correct. source: https://docs.oracle.com/cd/B19306_01/server.102/b14200/queries004.htm
upvoted 1 times
...
Sagarkpvs
1 year, 9 months ago
DE , tested that
upvoted 1 times
...
Poke90
1 year, 10 months ago
Selected Answer: DE
Definitely not BC
upvoted 1 times
...
jfc1
1 year, 12 months ago
Selected Answer: DE
B is incorrect because it is not mandatory to have an alias for each column in the first SELECT select first_name ||''||last_name, employee_id from hr.employees union select first_name,employee_id from HR.EMPLOYEES order by 1,2; C is incorrect because the datatypes : BLOC,CLOB are not valid the set Operators. DE is the correct answer.
upvoted 1 times
...
dexdinh91
2 years ago
Selected Answer: DE
DE are correct
upvoted 1 times
...
Viviana3184
2 years ago
DE are correct
upvoted 1 times
...
anzac
2 years, 1 month ago
According to: https://docs.oracle.com/cd/B19306_01/server.102/b14200/queries004.htm "If both queries select values of datatype CHAR of equal length, then the returned values have datatype CHAR of that length. If the queries select values of CHAR with different lengths, then the returned value is VARCHAR2 with the length of the larger CHAR value." AND "In queries using set operators, Oracle does not perform implicit conversion across datatype groups. " So DE.
upvoted 4 times
...
Renad_16
2 years, 1 month ago
I think it’s BD?
upvoted 1 times
Orxan_H
1 year, 8 months ago
B may be correct if in the end will be "order by" clause. Therefore DE correct
upvoted 2 times
...
...
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 ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago