From open-jpa-dev-return-2397-apmail-incubator-open-jpa-dev-archive=incubator.apache.org@incubator.apache.org Mon Feb 26 14:52:39 2007 Return-Path: Delivered-To: apmail-incubator-open-jpa-dev-archive@locus.apache.org Received: (qmail 29289 invoked from network); 26 Feb 2007 14:52:38 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 26 Feb 2007 14:52:38 -0000 Received: (qmail 16834 invoked by uid 500); 26 Feb 2007 14:52:47 -0000 Delivered-To: apmail-incubator-open-jpa-dev-archive@incubator.apache.org Received: (qmail 16716 invoked by uid 500); 26 Feb 2007 14:52:46 -0000 Mailing-List: contact open-jpa-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: open-jpa-dev@incubator.apache.org Delivered-To: mailing list open-jpa-dev@incubator.apache.org Received: (qmail 16706 invoked by uid 99); 26 Feb 2007 14:52:46 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 26 Feb 2007 06:52:46 -0800 X-ASF-Spam-Status: No, hits=1.2 required=10.0 tests=RCVD_IN_SORBS_WEB,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: domain of tommut@gmail.com designates 209.85.132.243 as permitted sender) Received: from [209.85.132.243] (HELO an-out-0708.google.com) (209.85.132.243) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 26 Feb 2007 06:52:34 -0800 Received: by an-out-0708.google.com with SMTP id b2so818659ana for ; Mon, 26 Feb 2007 06:52:13 -0800 (PST) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:user-agent:mime-version:to:subject:references:in-reply-to:content-type:content-transfer-encoding; b=T7tA70aRjrGbuo4zWzcCBONNKw2WwoEhJvV6dAHa5Z2who5k3wYto81oJdIOYPhU7w25MlzNmrjBDKuM78Cd/CyVRVrvL//cQ1YZcu1GCDPKMacMaTTQpSJ4esBnnJcGQImA/dgyXR5TrFnSpd2gTJAPCOcIzZySfjn+CcqsCx8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:user-agent:mime-version:to:subject:references:in-reply-to:content-type:content-transfer-encoding; b=Y+Ysi/7AwI1OsOaxRNmG4hhhN2ADbqZPNbJ67hYaqo+YDs6kWOVXpKZhGh879u+ceQ81w7jWZrqrlbDZi0uJDXv5qglHYMIH85pscCXTBdEROfsN+VrgoRTZ4gcVzgpot8gnS6wI9Eht1jmLnHZA7RHpKDaQGw48jJnDR9CVXS4= Received: by 10.100.107.2 with SMTP id f2mr511289anc.1172501533932; Mon, 26 Feb 2007 06:52:13 -0800 (PST) Received: from ?9.37.209.204? ( [129.33.49.251]) by mx.google.com with ESMTP id 13sm3831787wrl.2007.02.26.06.51.58; Mon, 26 Feb 2007 06:52:05 -0800 (PST) Message-ID: <45E2F402.1090403@gmail.com> Date: Mon, 26 Feb 2007 09:51:46 -0500 From: Tom Mutdosch User-Agent: Thunderbird 2.0b2 (Windows/20070116) MIME-Version: 1.0 To: open-jpa-dev@incubator.apache.org Subject: Re: possible to write a JPA Query to that filters both an Entity and its relationship entities? References: <45DDFB3F.2090205@gmail.com> <5240F16C-5619-4174-8754-6940EE6CCDF8@SUN.com> <7D856CDFE035FF45A0420ACBD71BDD63034FDFF6@repbex02.amer.bea.com> <45DF635C.1040305@gmail.com> <6339526B-4042-44FC-9A6C-AB868CB639D9@SUN.com> <7D856CDFE035FF45A0420ACBD71BDD63034FE2E1@repbex02.amer.bea.com> <91748938-8FEF-4941-9938-0986030F281A@SUN.com> <45DFAE10.8030406@gmail.com> <7D856CDFE035FF45A0420ACBD71BDD63034FE496@repbex02.amer.bea.com> In-Reply-To: <7D856CDFE035FF45A0420ACBD71BDD63034FE496@repbex02.amer.bea.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org Very cool. That sounds like the direction that I might want to go for this particular scenario. Thanks again to everyone for the helpful info and suggestions! Tom Patrick Linskey wrote: > Cool! > > So to implement something like the constructor stuff Craig was referring > to, you'd do: > > select new com.example.jpa.MyDataTransferObject(dept, oldTimers) from > ... > > This should return a List, populated lazily if so > configured. > > -Patrick > >