Hi,
I'm having difficulty in building the count query in hibernate with two join tables.
The POJO mapping class in one table has the reference to the other table.
Table A has sequenceno,uin
Table b has sequenceno,status
I need the count of uin in table A for the corresponding seq no.
and Sequenceno in table A is mapped to sequence no in table B with foriegn key and the corresponding Pojo class in table A has reference to table B for sequenceno as private A a;
Could any body help me out in building the count query in hibernate.
Could any one let me know how to convert the following sql query into hibenate
select count(uin) from A,B where A.sequenceno=B.sequenceno and A.sequenceno=1;
Thanks
|