Home » Oracle » 1z0-898 » Which statement is correct about the Java Persistence API support for the SQL queries?
Which statement is correct about the Java Persistence API support for the SQL queries?
A. SQL queries are NOT allowed to use parameters.
B. The result of an SQL query is not limited to entities.
C. Only SELECT SQL queries are required to be supported.
D. SQL queries are expected to be portable across databases.
Correct Answer: C
Explanation/Reference:
Explanation:
The Java Persistence Query Language (JPQL) is a platform-independent object-oriented query language defined as part of the Java Persistence API (JPA) specification.
In addition to retrieving objects (SELECT queries), JPQL supports set based UPDATE and DELETE queries.
Incorrect:
Not B:EntityManager API offers methods for creating instances of Query for executing native SQL statements. The most important thing to understand about native SQL queries created with EntityManager methods is that they, like JPQL queries, return entity instances, rather than database table records.
References:
Download Printable PDF. VALID exam to help you PASS.
|
|