Which two statements about the Query.executeUpdate method are true?

The Java Persistence API defines the Query interface. Which two statements about the
Query.executeUpdate method are true? (Choose two.)

The Java Persistence API defines the Query interface. Which two statements about the
Query.executeUpdate method are true? (Choose two.)

A.
Itmust always be executed within a transaction.

B.
It throws a PersistenceException if no entities were updated.

C.
It throws an HlegalStateException if called on a Query instance created with a Java Persistence
SELECT query.

D.
All managed entity objects corresponding to database rows affected by the update will have
their state changed to correspond with the update.



Leave a Reply 0

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