Difference between
version 90
and
version 89:
| At line 206 added 1 line. |
|
| At line 347 removed 21 lines. |
|
| You'll notice here that we're doing nothing with the ''person'' parameter. This is just a placeholder for now - in the future you may want to filter on it's properties using [Hibernate's Query Language|http://www.hibernate.org/hib_docs/reference/en/html/queryhql.html] (HQL) or using [Criteria Queries|http://www.hibernate.org/hib_docs/reference/en/html/querycriteria.html]. |
|
| ''An example using a Criteria Query:'' |
|
| [{Java2HtmlPlugin |
|
| Example example = Example.create(person) |
| .excludeZeroes() // exclude zero valued properties |
| .ignoreCase(); // perform case insensitive string comparisons |
| try { |
| return getSession().createCriteria(Person.class) |
| .add(example) |
| .list(); |
| } catch (Exception e) { |
| throw new DataAccessException(e.getMessage()); |
| } |
| return new ArrayList(); |
|
| }] |
|
Back to CreateDAO,
or to the Page History.
|