Skip to content

Instantly share code, notes, and snippets.

Created April 8, 2011 06:29
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/909394 to your computer and use it in GitHub Desktop.
Save anonymous/909394 to your computer and use it in GitHub Desktop.
QEmployee qEmployee = QEmployee.employee;
List<Employee> emps = sqlQuery.from(qEmployee)
.where(qEmployee.name.eq(name))
.list(new QBean<Employee>(Employee.class, qEmployee.id, qEmployee.name));
// QBean defines a Bean populating projection, the first argument is the Bean class and the rest the paths to be used for Bean population
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment