This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
hi, I do the same thing like you , but i don't understand how jpa know that which field need to distinct ?
My jpql is
select DISTINCT new model.Loggoldtmp( DATE_FORMAT(createdate, '%Y-%m-%d') as datevalue,year(createdate) as yearvalue,month(createdate) as monthvalue,quarter(createdate) as seasonvalue,dayofyear(createdate) as dayofyearvalue,dayofmonth(createdate) as dayofmonthvalue,dayofweek(createdate) as dayofweekvalue ,now() as createdate) "+
"from Loggold o";