Return-Path: Delivered-To: apmail-db-derby-user-archive@www.apache.org Received: (qmail 57913 invoked from network); 21 Jul 2006 09:45:55 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 21 Jul 2006 09:45:55 -0000 Received: (qmail 6135 invoked by uid 500); 21 Jul 2006 09:45:53 -0000 Delivered-To: apmail-db-derby-user-archive@db.apache.org Received: (qmail 6106 invoked by uid 500); 21 Jul 2006 09:45:53 -0000 Mailing-List: contact derby-user-help@db.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: List-Id: Reply-To: "Derby Discussion" Delivered-To: mailing list derby-user@db.apache.org Received: (qmail 6095 invoked by uid 99); 21 Jul 2006 09:45:53 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 21 Jul 2006 02:45:53 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=UNPARSEABLE_RELAY X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [192.18.98.36] (HELO brmea-mail-4.sun.com) (192.18.98.36) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 21 Jul 2006 02:45:52 -0700 Received: from phys-epost-1 ([129.159.136.14]) by brmea-mail-4.sun.com (8.13.6+Sun/8.12.9) with ESMTP id k6L9jVFI007497 for ; Fri, 21 Jul 2006 03:45:32 -0600 (MDT) Received: from conversion-daemon.epost-mail1.sweden.sun.com by epost-mail1.sweden.sun.com (iPlanet Messaging Server 5.2 HotFix 1.24 (built Dec 19 2003)) id <0J2Q00J01YX86E@epost-mail1.sweden.sun.com> (original mail from Andreas.Korneliussen@Sun.COM) for derby-user@db.apache.org; Fri, 21 Jul 2006 11:45:31 +0200 (MEST) Received: from [129.159.112.247] (khepri35.Norway.Sun.COM [129.159.112.247]) by epost-mail1.sweden.sun.com (iPlanet Messaging Server 5.2 HotFix 1.24 (built Dec 19 2003)) with ESMTPA id <0J2Q006L4Z3U4W@epost-mail1.sweden.sun.com> for derby-user@db.apache.org; Fri, 21 Jul 2006 11:45:31 +0200 (MEST) Date: Fri, 21 Jul 2006 11:45:30 +0200 From: Andreas Korneliussen Subject: Re: Embedded driver support for ResultSet.getRow In-reply-to: To: Derby Discussion Reply-to: Andreas.Korneliussen@Sun.COM Message-id: <44C0A23A.8080500@sun.com> Organization: Sun Microsystems MIME-version: 1.0 Content-type: text/plain; charset=ISO-8859-1; format=flowed Content-transfer-encoding: 7BIT User-Agent: Thunderbird 1.5.0.2 (X11/20060427) References: X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Matt Frantz wrote: > I am porting an application from PostgreSQL to Derby. I use ResultSet.getRow() > to keep track of whether a particular row has been processed. However, I get an > error like this: > > The 'getRow()' method is only allowed on scroll cursors > I could not find anything in JavaDoc for ResultSet.getRow() which indicates that getRow() should not be allowed on forward-only result sets. So this may be a bug in Derby. > It seems that even a forward iterator should be able to keep count of the rows, > so this method should be supported. Am I mistaken about the semantics of this > method? Is there another way to know which row I'm on without using scrolling > ResultSets, which (according to the docs) read the results into memory? > The docs are out-of-date. I am not sure exactly which version, however at least since 10.1.2 scrollable resultsets will back the data to disk (to a temporary table) if the result set is huge. Regards Andreas > Regards, > Matt Frantz > >