Last answered:

04 May 2024

Posted on:

05 Jun 2023


Course Exam : Question 8 & 9

Dear 365datascience team,
For question 8, I find it hard to figure out how come the place of "where" condition would make such a difference?
Since we're all using "INNER JOIN" in this case, the condition should been applied to all the result set as well, regardless of placing it in the subquery or not, right? I would need your further explanation in detail to this question.
For question 9, after type in the code and get the result, I find out that the choice between a (g.genre_id, a.genre_id, s.genre_id) would make no differences to the result, but the (s.release_date & a.release_date).
Thank you!

1 answers ( 0 marked as helpful)
Posted on:

04 May 2024



Thanks for reaching out.

Please accept my apologies for the delayed response due to badly managed Q and A response on our end. 

Question 8: "Placing it" - do you mean the WHERE clause? If yes, then no, it is not the same whether it is within our outsied the subquery. The subquery refers to a certain subset of the data, so if it contains or not a WHERE clause it will impact the output of the INNER JOIN of the outer query.

Question 9: There is only one correct answer from the provided suggestions.

Hope this helps.

Submit an answer