Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 1576 invoked from network); 20 Jun 2007 01:31:48 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 20 Jun 2007 01:31:48 -0000 Received: (qmail 48975 invoked by uid 500); 20 Jun 2007 01:31:51 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 48760 invoked by uid 500); 20 Jun 2007 01:31:51 -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 48567 invoked by uid 99); 20 Jun 2007 01:31:51 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 19 Jun 2007 18:31:50 -0700 X-ASF-Spam-Status: No, hits=-100.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 19 Jun 2007 18:31:46 -0700 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 4C93D7141FC for ; Tue, 19 Jun 2007 18:31:26 -0700 (PDT) Message-ID: <18695601.1182303086311.JavaMail.jira@brutus> Date: Tue, 19 Jun 2007 18:31:26 -0700 (PDT) From: "Myrna van Lunteren (JIRA)" To: derby-dev@db.apache.org Subject: [jira] Updated: (DERBY-2386) timestampdiff function fails when using SQL_TSI_FRAC_SECOND for datepart parameter, except for very small intervals In-Reply-To: <5899350.1172769710673.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/DERBY-2386?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Myrna van Lunteren updated DERBY-2386: -------------------------------------- Derby Info: [Existing Application Impact, Release Note Needed] (was: [Existing Application Impact]) > timestampdiff function fails when using SQL_TSI_FRAC_SECOND for datepart parameter, except for very small intervals > ------------------------------------------------------------------------------------------------------------------- > > Key: DERBY-2386 > URL: https://issues.apache.org/jira/browse/DERBY-2386 > Project: Derby > Issue Type: Bug > Components: SQL > Affects Versions: 10.2.2.0 > Environment: SUSE Linux Enterprise Desktop 10 > Reporter: Don Smith > Assignee: Mayuresh Nirhali > Fix For: 10.3.0.0 > > Attachments: derby2386-v2.diff, derby2386.diff, releaseNote.html, releaseNote.html > > > Using the timestampdiff function produces and integer overflow except for very small intervals. Error message is: > [Error Code: -1, SQL State: 22003] The resulting value is outside the range for the data type INTEGER. > I inserted the following row into my test table: > insert into datetest (ID, > startdate, > enddate) values ( > 5, > '2006-11-20 04:20:00.0', > '2006-11-20 04:20:00.2'); > This test row works: > select {fn timestampdiff(SQL_TSI_FRAC_SECOND, startdate, enddate)} as diff from datetest where id = 5 > DIFF > 200000000 > The value also looks too large, which could be exacerbating the problem. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.