What to use: JPQL or Criteria API? [closed]
My Java application is using JPA for object persistence. The business domain is very simple (just three classes are persistent, with 3-5 properties in each). Queries are simple as well. The question is which approach I should use: JPQL or Criteria API? Pascal Thivent I'm pretty sure this has already been covered here on SO but I couldn't find the existing question. So, here is my point of view on the question: I find JPQL queries easier to write/read. I find the Criteria API nice for building dynamic queries. Which is basically what you'll find in Hibernate: Criteria vs. HQL . But there is one