Hi Ivan,
I solved the problem this way:
Code:
try {
final Criteria criteria = HibernateUtil.getSession().createCriteria(IContract.class);
ProjectionList projections = Projections.projectionList();
projections.add(Projections.property("value.value"));
projections.add(Projections.property("value.currency"));
criteria.setProjection(projections);
return criteria.list();
} catch (HibernateException he) {
throw new FinderException(he.getMessage(), he);
}
This way I receive Tuples of BigDecimal and Currency. Then you can use a ResultTransformer to transform it into whatever you want.
I hope this is helpful.
Greetings,
Stefan