Exam 1z0-071 All QuestionsBrowse all questions from this exam
Question 83

Examine the data in the ORDERS table:

Examine the data in the INVOICES table:

Examine this query:

    Correct Answer: B, F

    To determine the correct answers, we need to understand how the INTERSECT operator works. The INTERSECT operator returns only the rows that are present in both SELECT statements. Therefore, we need to find common `order_id` and `order_date` pairs in both the ORDERS and INVOICES tables. On examining the two tables, we see that there is only one matching pair: (4, 01-FEB-2019) in both tables. The pair (1, null) is not considered a match because the INTERSECT operator does not consider null values as a match in SQL. So, the correct pair is (4, 01-FEB-2019). Hence, the answers are B and F.

Discussion
abdullah_barhamOptions: BF

drop table orders; create table orders(order_id number , order_date date); insert into orders values(1,null); insert into orders values(2,null); insert into orders values(3,'1-jan-2019'); insert into orders values(4,'1-feb-2019'); insert into orders values(5,'1-mar-2019'); create table invoices( invoice_id number, order_id number, order_date date); insert into invoices values(1,1,null); insert into invoices values(2,2,'01-jan-2019'); insert into invoices values(3,3,null); insert into invoices values(4,4,'01-feb-2019'); insert into invoices values(5,5,'01-APR-2019'); SELECT ORDER_ID , ORDER_DATE FROM ORDERS INTERSECT SELECT ORDER_ID , ORDER_DATE FROM INVOICES; ANSWER IS B,F.

Mcromeo

Based on your own example, it return 2 rows. so B is not correct

Rik92

This needs an update badly. There is no question, just some tables and a query showing on this site..

SantiBZ_07032022_1744

Tesded: 1 null 4 01/02/19 00:00:00

cadcadley

bf only if F is 01-FEB-2019 and not 01-FEB-2015 i am sorry then is B only

Viviana3184

bf only if F is 01-FEB-2019 and not 01-FEB-2015

ArslanAltafOption: B

I think the question is what the result of intersect The result will only include rows where both the order_id and order_date match between the ORDERS and INVOICES tables. So, order ID 1& 4 has exact match -------- but the 4 1-Fab-2019 is not in result (if you dont consider the Typo in option F) B seems to be the answer in given circumstances

Fargo01Option: B

Best answer is B. 01-FEB-2019

uselessscript

Just finished this exam. Question: Which three results will be returned?

metallersOptions: BF

La respuesta es la B y la F

SangiiiOptions: BF

B and F is answer- below is the result we will get. F option has typo 01-FEB-2019 orderid order_date 1 (null) 4 01-02-19

AishMani20

Question is not there

zouve

In Oracle, the INTERSECT operator is used to combine the result sets of two or more SELECT statements and returns only the rows that are common to all result sets.

NelitaOptions: BF

BF ARE CORRECT

kuffOptions: BF

BF is the answer

Ricx24Options: BEF

I already took the exam ant these question ask for 3 answers B, E, F

Shakhzod1999

can you write to me on telegram @Melsson

jfc1

BF is the answer

cadcadley

is t 100% bf went we do created everything