You are writing a query about hospital encounters using the following FROM clause: FROM PAT_ENC HSP peh CLARITY_DEP dep ON peh.DEPARTMENT_ID = dep.DEPARTMENT_ID DEPARTMENT_ID is never NULL in either table, and for every DEPARTMENT_ID in PAT_ENC_HSP, there is a matching DEPARTMENT_ID in CLARITY_DEP. Assuming no additional filtering, which join type must you use? A. You must use either an INNER JOIN or a LEFT OUTER JOIN, and either would return the same results B. You must use an INNER JOIN C. You must use a LEFT OUTER JOIN D. You must use a CROSS JOIN

Database Systems: Design, Implementation, & Management
11th Edition
ISBN:9781285196145
Author:Steven, Steven Morris, Carlos Coronel, Carlos, Coronel, Carlos; Morris, Carlos Coronel and Steven Morris, Carlos Coronel; Steven Morris, Steven Morris; Carlos Coronel
Publisher:Steven, Steven Morris, Carlos Coronel, Carlos, Coronel, Carlos; Morris, Carlos Coronel and Steven Morris, Carlos Coronel; Steven Morris, Steven Morris; Carlos Coronel
Chapter3: The Relational Database Model
Section: Chapter Questions
Problem 3P: Do the tables exhibit referential integrity? Answer yes or no, and then explain your answer. Write...
icon
Related questions
Question

You are writing a query about hospital encounters using the following FROM clause:

FROM PAT_ENC HSP peh
<join type> CLARITY_DEP dep ON peh.DEPARTMENT_ID = dep.DEPARTMENT_ID

DEPARTMENT_ID is never NULL in either table, and for every DEPARTMENT_ID in PAT_ENC_HSP, there is a matching DEPARTMENT_ID in CLARITY_DEP. Assuming no additional filtering, which join type must you use?

A. You must use either an INNER JOIN or a LEFT OUTER JOIN, and either would return the same results

B. You must use an INNER JOIN

C. You must use a LEFT OUTER JOIN

D. You must use a CROSS JOIN

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps

Blurred answer
Knowledge Booster
Intermediate SQL concepts
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781285196145
Author:
Steven, Steven Morris, Carlos Coronel, Carlos, Coronel, Carlos; Morris, Carlos Coronel and Steven Morris, Carlos Coronel; Steven Morris, Steven Morris; Carlos Coronel
Publisher:
Cengage Learning
Programming with Microsoft Visual Basic 2017
Programming with Microsoft Visual Basic 2017
Computer Science
ISBN:
9781337102124
Author:
Diane Zak
Publisher:
Cengage Learning
Oracle 12c: SQL
Oracle 12c: SQL
Computer Science
ISBN:
9781305251038
Author:
Joan Casteel
Publisher:
Cengage Learning
A Guide to SQL
A Guide to SQL
Computer Science
ISBN:
9781111527273
Author:
Philip J. Pratt
Publisher:
Course Technology Ptr