Which statement is true?

An application has two entities, Department and Employee, and there is a one-to-many relationship between them. The application has the following query:
SELECT d
FROM Department d LEFT JOIN FETCH d. employees
WHERE d.name = : name
After receiving the results of the query, the application accesses the returned department’s Employee entities stored in the Department.employees collection-valued attribute.
All caching has been turned off in the application.
Which statement is true?
A. The database will be accessed once during the query execution phase, and once for each Employee entity in Department – employees.
B. The database will be accessed once during the query execution phase ONLY.
C. The database will be accessed once during the query execution phase, and once when the department.employees collection-valued attribute is used.
D. The database will be accessed once during the query execution phase, once when the Department.
Employees collection-valued attribute is used, and once for each employee entity in the Department.employees.

Download Printable PDF. VALID exam to help you PASS.

Leave a Reply

Your email address will not be published. Required fields are marked *


The reCAPTCHA verification period has expired. Please reload the page.