sum « Field « JPA Q&A





1. Can HQL substract or sum date fields?    stackoverflow.com

A have two entities. For example timing settings and orders.

@Entity
public class TimingSettings{

    @Basic
    private Long orderTimeout = 18000; //for example 18000 sec
   ...

2. Grails: sum of field within criteria builder    stackoverflow.com

I'm at a loss of how to create a running sum of particular field after creating a criteria within a controller I'm currently creating a set of set of records using:

 ...

3. is it a bug or can't i use sum(field_a*fieldb)    forum.hibernate.org

4. How to sum of a numberic field result of distinct query    forum.hibernate.org

Hi I want to write a hql ( query in hibernate ) , My problem is that in my one query the result of that query is come using distinct , not i want to sum of one field carried out from that distinct query but it also distinct in sum method too. Can i use sub table in hql e.g ...