clazz = object.getClass();
SelectCommand scmd = DAOFactory.getSelectCommand(clazz);
Filter filter1 = DAOFactory.getFilter("roleId", SQLOperator.EQUAL,
creatorId);
scmd.setFilter(filter1);
ArrayList creators = session.query(scmd);
String creatorName = "";
if (creators.size() > 0) {
Role creator = (Role) creators.get(0);
creatorName = creator.getRoleName();
}