Package com.mysema.query.jpa.domain.sql

Examples of com.mysema.query.jpa.domain.sql.SAnimal


    }

    @Test
    @ExcludeIn(Target.DERBY)
    public void Union3() {
        SAnimal cat2 = new SAnimal("cat2");
        List<Tuple> rows = query().union(
            new SQLSubQuery().from(cat).innerJoin(cat2).on(cat2.id.eq(cat.id)).list(cat.id, cat2.id),
            new SQLSubQuery().from(cat).list(cat.id, null))
        .list();
View Full Code Here


    }

    @Test
    @ExcludeIn({Target.DERBY, Target.ORACLE})
    public void Union5() {
        SAnimal cat2 = new SAnimal("cat2");
        List<Tuple> rows = query().union(
            new SQLSubQuery().from(cat).join(cat2).on(cat2.id.eq(cat.id.add(1))).list(cat.id, cat2.id),
            new SQLSubQuery().from(cat).join(cat2).on(cat2.id.eq(cat.id.add(1))).list(cat.id, cat2.id))
        .list();
View Full Code Here

        }
    }

    @Test
    public void EntityQueries_CreateQuery() {
        SAnimal cat = new SAnimal("cat");
        QCat catEntity = QCat.cat;

        Query query = query().from(cat).createQuery(catEntity);
        assertEquals(6, query.getResultList().size());
    }
View Full Code Here

    }

    @Test
    @ExcludeIn(Target.MYSQL)
    public void EntityQueries_CreateQuery2() {
        SAnimal cat = new SAnimal("CAT");
        QCat catEntity = QCat.cat;

        Query query = query().from(cat).createQuery(catEntity);
        assertEquals(6, query.getResultList().size());
    }
View Full Code Here

TOP

Related Classes of com.mysema.query.jpa.domain.sql.SAnimal

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.