for example there are 2 properties house number and pincode and i want a single property as address like house number is 10 and pincode is 110064 and combine address property is 10,110064 this is my code
final Criteria criteria= getDatabaseSession().createCriteria(Application.class, "application");
final ProjectionList projectionList=Projections.projectionList();
criteria.setProjection(projectionList);
projectionList.add(Projections.property("address.street"), "street");
projectionList.add(Projections.property("address.postcode"), "postcode");
projectionList.add(Projections.property("address.houseNumber"), "houseNumber");
criteria.createAlias("application.applicationCase", "applicationCase", JoinType.INNER_JOIN);
criteria.createAlias("applicationCase.property", "property");
criteria.createAlias("property.address", "address");
criteria.setResultTransformer(Criteria.ALIAS_TO_ENTITY_MAP);
return (Map<String, Object>) criteria.uniqueResult();
and i want to do something like this
projectionList.add(Projections.property("address.street"+"address.houseNumber"+"address.postcode"),"address");
can somebody help.