java - timestampdiff equivalent in JPQL (without using criteria) -


i want use following mysql function in jpql:-

timestampdiff(year, some_start_date, curdate()); 

also, not have use criteria in jpa, since following practice of writing named queries(jpql). so, how can function written in jpql?

there no timestampdiff in jpql. eclipse has keyword func allows call db-specific functions, timestampdiff.


Comments

Popular posts from this blog

java - WARN : org.springframework.web.servlet.PageNotFound - No mapping found for HTTP request with URI [/board/] in DispatcherServlet with name 'appServlet' -

android - How to create dynamically Fragment pager adapter -

1111. appearing after print sequence - php -