Package org.apache.openjpa.persistence.query

Examples of org.apache.openjpa.persistence.query.Expression


    }
   
    public void testConcat() {
        DomainObject e = qb.createQueryDefinition(Employee.class);
        DomainObject f = e.join("frequentFlierPlan");
        Expression c =
        e.generalCase().when(f.get("annualMiles").greaterThan(50000)).then(
                "Platinum").when(f.get("annualMiles").greaterThan(25000)).then(
                "Gold").elseCase("XYZ");
        e.select(e.get("name"), f.get("name"), e.concat(c, e
            .literal("Frequent Flyer")));
View Full Code Here


    }
   
    public void testConcat() {
        DomainObject e = qb.createQueryDefinition(Employee.class);
        DomainObject f = e.join("frequentFlierPlan");
        Expression c =
        e.generalCase().when(f.get("annualMiles").greaterThan(50000)).then(
                "Platinum").when(f.get("annualMiles").greaterThan(25000)).then(
                "Gold").elseCase("XYZ");
        e.select(e.get("name"), f.get("name"), e.concat(c, e
            .literal("Frequent Flyer")));
View Full Code Here

TOP

Related Classes of org.apache.openjpa.persistence.query.Expression

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.