Hi All,
I'm using MySQL, I have a table in which one column is of time type and I have a requirement to find out the sum of that column. The problem is column is of time type and if i am using sum method of projections then the result is not correct.
The following query returns the desired result: SELECT SUM(TIME_TO_SEC(time_detail)) FROM demo.test t;
Please suggest if there is any way to to call MySQL functions using hibernate. I'm looking for a solution other than native SQL queries like session.createSQLQuery().
_________________ Thanks, Sandeep Bhardwaj
|