select sa.account_id "Account id",date_format(rph.trn_date,'%d-%m-%Y') "Date",if(rph.trn_type=6,rph.total_trn_value,"") "Deposit",
if(rph.trn_type=7,rph.total_trn_value,"") "Withdraw",
cgcm.display_name "Customer name"
from saving_accounts sa,receipt_payment_header rph,
center_group_customer_master cgcm
where rph.trn_date between $P{fromDate} and $P{toDate} and
sa.customer_id=rph.customer_id and
sa.savings_id=rph.account_id and
rph.customer_id=cgcm.customer_id and sa.del_flag='N' and
cgcm.del_flag='N' and sa.status='V' and rph.status='V' and
cgcm.status='A' and rph.total_trn_value!=0 and rph.prd_type_id=2 and
rph.trn_type in(6,7) order by rph.trn_date;
Please help me on converting this query into hibernate query my mail id is
deepakbalagopal@gmail.com.