Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 80055 invoked from network); 29 Jun 2009 14:22:00 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 29 Jun 2009 14:22:00 -0000 Received: (qmail 13743 invoked by uid 500); 29 Jun 2009 14:22:10 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 13678 invoked by uid 500); 29 Jun 2009 14:22:10 -0000 Mailing-List: contact derby-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: Delivered-To: mailing list derby-dev@db.apache.org Received: (qmail 13654 invoked by uid 99); 29 Jun 2009 14:22:09 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 29 Jun 2009 14:22:09 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 29 Jun 2009 14:22:07 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 5C3A1234C055 for ; Mon, 29 Jun 2009 07:21:47 -0700 (PDT) Message-ID: <1508397665.1246285307376.JavaMail.jira@brutus> Date: Mon, 29 Jun 2009 07:21:47 -0700 (PDT) From: "Dag H. Wanvik (JIRA)" To: derby-dev@db.apache.org Subject: [jira] Updated: (DERBY-2139) executing getXXX() for a column checks the column position is in range three times, reduce to one. In-Reply-To: <19186105.1165086501013.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/DERBY-2139?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Dag H. Wanvik updated DERBY-2139: --------------------------------- Derby Categories: [Performance] > executing getXXX() for a column checks the column position is in range three times, reduce to one. > -------------------------------------------------------------------------------------------------- > > Key: DERBY-2139 > URL: https://issues.apache.org/jira/browse/DERBY-2139 > Project: Derby > Issue Type: Improvement > Components: JDBC, SQL > Reporter: Daniel John Debrunner > Priority: Minor > Attachments: d2139_getXXX_draft.txt > > > On a getXXX() method the column position is checked in: > Once in EmbedResultSet.getColumn() > Twice in ValueRow.getColumn() > - once using explict code > - once implicitly when accessing the DataValueDescriptor array > Can reduce to once by solely relying on the array bounds checking. Then change the defined api to Row.getColumn to state that it throws IndexOutOfBoundsException for an invalid column. EmbedResultSet.getColumn() then can catch that exception and throw the required SQLException. > Probably need similar changes on the setXXX() methods and other getXXX methods and need to see how Row.getColumn() is used within the language layer. > -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.