Return-Path: Delivered-To: apmail-ibatis-user-java-archive@www.apache.org Received: (qmail 96679 invoked from network); 7 Apr 2006 13:16:19 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 7 Apr 2006 13:16:19 -0000 Received: (qmail 65253 invoked by uid 500); 7 Apr 2006 13:16:16 -0000 Delivered-To: apmail-ibatis-user-java-archive@ibatis.apache.org Received: (qmail 65065 invoked by uid 500); 7 Apr 2006 13:16:15 -0000 Mailing-List: contact user-java-help@ibatis.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user-java@ibatis.apache.org Delivered-To: mailing list user-java@ibatis.apache.org Received: (qmail 65054 invoked by uid 99); 7 Apr 2006 13:16:15 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 07 Apr 2006 06:16:15 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [195.130.132.54] (HELO hoefnix.telenet-ops.be) (195.130.132.54) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 07 Apr 2006 06:16:14 -0700 Received: from nocme1bl6.telenet-ops.be (nocme1bl6.telenet-ops.be [195.130.136.37]) by hoefnix.telenet-ops.be (Postfix) with ESMTP id E2120A0103 for ; Fri, 7 Apr 2006 15:14:32 +0200 (CEST) Received: from nocme1bl6.telenet-ops.be (localhost.localdomain [127.0.0.1]) by nocme1bl6.telenet-ops.be (Postfix) with ESMTP id CCAF6388052; Fri, 7 Apr 2006 15:14:32 +0200 (CEST) From: "Sven.Boden" To: user-java@ibatis.apache.org, user-java@ibatis.apache.org Importance: Normal Sensitivity: Normal Message-ID: X-Originating-IP: [192.85.50.2] X-Forwarded-For: [(null)] Date: Fri, 07 Apr 2006 13:14:32 +0000 Subject: Re: Problems with groupBy MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Erica, Start by using the version of iBATIS in SVN... there is a known bug in 2.= 1.7 and before when nesting groupBy's. Regards, Sven >----- Oorspronkelijk bericht ----- >Van: Erica Cody [mailto:AID9C23@idpa.state.il.us] >Verzonden: vrijdag, april 7, 2006 02:25 PM >Aan: user-java@ibatis.apache.org >Onderwerp: Problems with groupBy > >Help!! I am having problems getting my groupBy to work. My query brings= back 5 rows, but the businessEmployeesList collection is not populated f= or any of the business objects. Here is my mapping: > > > .................... <-- all properties f= or this table > > > > .................... <-- all properties = for this table > > > > > > > > >I am using ArrayList list =3D (ArrayList)getSqlMapExecutor().queryForLis= t("getBusEmpRoleByIdNum", idNumber.trim()); to get the data > >When I debug this, it appears the businessEmployeesList collection is nu= ll, which would seem to make sense since it appears from the debug statem= ents that the role is being built after the list is populated (I have deb= ug statements in the constructors). Where are the Role records going? I= can see they are being built, but the List I get back only seems to have= the 5 business objects! I have tried removing the groupBy on the busine= ssResult map, adding it to the busEmpRoleResult map and every combination= of the two, but no approach seems to work. Does anybody have any sugges= tions? Thanks!! > >[4/7/06 6:50:38:125 CDT] 792fe35e SystemOut O * Servlet.Engine.Tran= sports : 0 * * DEBUG common.model.Business - Building Business >[4/7/06 6:50:38:125 CDT] 792fe35e SystemOut O * Servlet.Engine.Tran= sports : 0 * * DEBUG common.model.Business - Adding new business list wi= th null employees for common.model.Business@a890 >[4/7/06 6:50:38:141 CDT] 792fe35e SystemOut O * Servlet.Engine.Tran= sports : 0 * * DEBUG common.model.Role - Building Role >[4/7/06 6:50:38:141 CDT] 792fe35e SystemOut O * Servlet.Engine.Tran= sports : 0 * * DEBUG common.model.Business - Building Business >[4/7/06 6:50:38:141 CDT] 792fe35e SystemOut O * Servlet.Engine.Tran= sports : 0 * * DEBUG common.model.Business - Adding new business list wi= th null employees for common.model.Business@a890 >[4/7/06 6:50:38:141 CDT] 792fe35e SystemOut O * Servlet.Engine.Tran= sports : 0 * * DEBUG common.model.Role - Building Role >[4/7/06 6:50:38:141 CDT] 792fe35e SystemOut O * Servlet.Engine.Tran= sports : 0 * * DEBUG common.model.Business - Building Business >[4/7/06 6:50:38:141 CDT] 792fe35e SystemOut O * Servlet.Engine.Tran= sports : 0 * * DEBUG common.model.Business - Adding new business list wi= th null employees for common.model.Business@a890 >[4/7/06 6:50:38:156 CDT] 792fe35e SystemOut O * Servlet.Engine.Tran= sports : 0 * * DEBUG common.model.Role - Building Role >[4/7/06 6:50:38:156 CDT] 792fe35e SystemOut O * Servlet.Engine.Tran= sports : 0 * * DEBUG common.model.Business - Building Business >[4/7/06 6:50:38:156 CDT] 792fe35e SystemOut O * Servlet.Engine.Tran= sports : 0 * * DEBUG common.model.Business - Adding new business list wi= th null employees for common.model.Business@a890 >[4/7/06 6:50:38:156 CDT] 792fe35e SystemOut O * Servlet.Engine.Tran= sports : 0 * * DEBUG common.model.Role - Building Role > > >