Package ch.inftec.ju.db.query.QueryUtils.NativeQueryBuilder

Examples of ch.inftec.ju.db.query.QueryUtils.NativeQueryBuilder.AttributeOrdering


  @DataSet("NativeQueryBuilderTest_dataTypes.xml")
  public void canOrder_byMultipleAttributes() throws Exception {
    Query qry1 = QueryUtils.createNativeQuery(this.em)
      .fromResourceRelativeTo(this.getClass(), "NativeQueryBuilderTest_canOrder_byAttribute.sql")
      .orderBy(new AttributeOrdering[] {
          new AttributeOrdering("intNumber", Ordering.ASCENDING)
          , new AttributeOrdering("bigIntNumber", Ordering.DESCENDING)
      })
      .createQuery();
   
    Assert.assertEquals(2, qry1.getResultList().size());
    this.assertIdEquals(2L, qry1.getResultList(), 0);
View Full Code Here

TOP

Related Classes of ch.inftec.ju.db.query.QueryUtils.NativeQueryBuilder.AttributeOrdering

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.