A User entity is in a one-to-many relationship with a Book entity.
A developer writes a query to delete users that have a first name of Fred1or ‘Ginger’, and writes
the following Java Persistence query language statement:
DELETE FROM User u WHERE u.name IN (Fred’, “Ginger)
If the query fails with a PersistenceException, what can be the cause?
A.
The syntax of the query is NOT correct.
B.
Thequerycauses a foreign key integrity constrainttobe violated.
C.
The database doesNOThave any userswith thenameFred’or ‘Ginger’.
D.
Theentities corresponding to the userswiththe nameFred’or’Ginger’ arealreadybeing
managedbythe persistencecontext.