// Check for multi column select
CriteriaQuery<Person> personQuery = criteriaBuilder.createQuery(Person.class);
Root<Person> from = personQuery.from(Person.class);
personQuery.select(from.alias("p"));
personQuery.orderBy(criteriaBuilder.desc(from.get("personName")));
String actual = CriteriaQueryTranslator.translate(personQuery);
Assert.assertEquals(expected.trim(), actual.trim());
}
@Test