Hibernate (Java)

Aus Tutorials
Zur Navigation springen Zur Suche springen

Sub Query

ExtendedDetachedCriteria voucherCriteria = ExtendedDetachedCriteria.forClass(DocumentParameters.class);
voucherCriteria.setProjection(Projections.property("targetVoucherType"));
voucherCriteria.add(Restrictions.eq("client", client));

ExtendedDetachedCriteria invoiceCriteria = ExtendedDetachedCriteria.forClass(IncomingInvoice.class);
invoiceCriteria.add(Subqueries.propertyIn("voucherType", voucherCriteria));


Zurück zu Java