воскресенье, 8 июня 2014 г.

Projection

- Great way to present objects to the UI
- Objects added using JPQL syntax
- Projection Objects can be JPA Entities
- Need a constructor for the projection

String jpql="Select new com.domain.model.GoalReport(g.minutes, e.minutes, e.activity) " +
  "from Goal g, Exercise e where g.id = e.goal.id";

Комментариев нет:

Отправить комментарий