deltaspike-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Johannes Häyry <johannes.ha...@vaadin.com>
Subject Generated query for count
Date Tue, 03 Nov 2015 07:43:40 GMT
Hello,
Is it possible to use generated query for count and if so, how is it done?
I was expecting Long countByFlagIsNotNull() to work, but instead I had to
add Query annotation like this:
@Query("select count(m) from Message m where m.flag is not null")

/Johannes

-- 
Johannes Häyry, Vaadin Expert
Vaadin.com <https://vaadin.com> - +358 443 564 403 - skype:johannes_vaadin

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message