X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 1842752C5E for ; Thu, 14 Jul 2005 20:47:37 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 27239-07 for ; Thu, 14 Jul 2005 23:47:27 +0000 (GMT) Received: from pop1.greatbasin.net (pop1.greatbasin.net [207.228.35.3]) by svr1.postgresql.org (Postfix) with ESMTP id 9D00452C34 for ; Thu, 14 Jul 2005 20:47:23 -0300 (ADT) Received: from [172.16.1.121] (rno-dsl0b-131.gbis.net [216.82.145.131]) by pop1.greatbasin.net (8.12.10/8.12.10) with ESMTP id j6ENlQw3013547 for ; Thu, 14 Jul 2005 16:47:26 -0700 Mime-Version: 1.0 (Apple Message framework v622) Content-Transfer-Encoding: 7bit Message-Id: Content-Type: text/plain; charset=US-ASCII; format=flowed To: pgsql-jdbc@postgresql.org From: Dianne Yumul Subject: No. of rows on result set Date: Thu, 14 Jul 2005 16:47:27 -0700 X-Mailer: Apple Mail (2.622) X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.005 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200507/90 X-Sequence-Number: 13238 Hello List, Recently upgraded to Postgresql 8.0.3, JDBC Driver 8.0 Build 311 and realized that I can no longer use the last() method for ResultSet because of the default TYPE_FORWARD_ONLY. Several of our apps use this to find the number of rows on a result set. Looking at the archives, my options would be to (1) do a separate SELECT COUNT(*) . . ., (2) change result set type to TYPE_SCROLL_INSENSITIVE, (3) replace arrays with something else that will not require the size of the result set, or (4) a better solution I haven't thought of : ). Sorry for the newbie question. I'm inclined to just use TYPE_SCROLL_INSENSITIVE, but I want to do this the right way (not just the easy way) and I'm not sure if it has any repercussions. Thank you very much. dianne