DY0-001 · Question #29
A movie production company would like to find the actors appearing in its top movies using data from the tables below. The resulting data must show all movies in Table 1, enriched with actors listed…
The correct answer is D. Perform a LEFT JOIN on Table 1 using column Movie, with Table 2 using column Acted_In. A LEFT JOIN returns every row from Table 1 (all top movies) and brings in matching actors from Table 2 where the Movie = Acted_In, leaving NULLs for movies without listed actors.
Question
A movie production company would like to find the actors appearing in its top movies using data from the tables below. The resulting data must show all movies in Table 1, enriched with actors listed in Table 2. Which of the following query operations achieves the desired data set?
Exhibit
Options
- APerform an INNER JOIN between Table 1 using column Movie, and Table 2 using column
- BPerform a UNION between Table 1 using column Movie, and Table 2 using column Acted_In.
- CPerform an INTERSECT between Table 1 using column Movie, and Table 2 using column
- DPerform a LEFT JOIN on Table 1 using column Movie, with Table 2 using column Acted_In.
How the community answered
(69 responses)- A1% (1)
- B1% (1)
- C3% (2)
- D94% (65)
Explanation
A LEFT JOIN returns every row from Table 1 (all top movies) and brings in matching actors from Table 2 where the Movie = Acted_In, leaving NULLs for movies without listed actors.
Topics
Community Discussion
No community discussion yet for this question.
