/**
* 使用sql语句进行查询操作
* @param sql
* @return
*/
public List queryWithSql(final String sql){
List list = hibernateTemplate.executeFind(new HibernateCallback() {
public Object doInHibernate(Session session) throws HibernateException,
SQLException {
Query query = session.createSQLQuery(sql);
List list = query.list();
return list;
}
});
return list;
}