Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 83801 invoked from network); 8 May 2008 04:05:19 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 8 May 2008 04:05:19 -0000 Received: (qmail 82341 invoked by uid 500); 8 May 2008 04:05:20 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 82318 invoked by uid 500); 8 May 2008 04:05:20 -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 82307 invoked by uid 99); 8 May 2008 04:05:20 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 07 May 2008 21:05:20 -0700 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; Thu, 08 May 2008 04:04:34 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id A7B99234C10C for ; Wed, 7 May 2008 21:04:55 -0700 (PDT) Message-ID: <1121082878.1210219495685.JavaMail.jira@brutus> Date: Wed, 7 May 2008 21:04:55 -0700 (PDT) From: "Bryan Pendleton (JIRA)" To: derby-dev@db.apache.org Subject: [jira] Resolved: (DERBY-2085) Misleading error message for non-matching ORDER BY clause in queries with GROUP BY. In-Reply-To: <19565692.1163583879068.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/DERBY-2085?page=3Dcom.atlassia= n.jira.plugin.system.issuetabpanels:all-tabpanel ] Bryan Pendleton resolved DERBY-2085. ------------------------------------ Resolution: Fixed Committed revised text for 42Y36 as revision 654404. The message now is more broadly worded to make it clear that the column in question may be either a simple column reference or may be part of a larger expression. > Misleading error message for non-matching ORDER BY clause in queries with= GROUP BY. > -------------------------------------------------------------------------= ---------- > > Key: DERBY-2085 > URL: https://issues.apache.org/jira/browse/DERBY-2085 > Project: Derby > Issue Type: Bug > Components: SQL > Affects Versions: 10.2.1.6 > Environment: Any > Reporter: =C3=98ystein Gr=C3=B8vlen > Assignee: Bryan Pendleton > Priority: Trivial > Fix For: 10.5.0.0 > > Attachments: newMsgWithTest.diff > > > In 10.2, this query gives the following error message: > ij> SELECT i FROM t GROUP BY i ORDER BY j; > ERROR 42Y30: The SELECT list of a grouped query contains at least one inv= alid expression. If a SELECT list has a GROUP BY, the list may only contain= valid grouping expressions and valid aggregate expressions. =20 > This is misleading since there is no invalid expression in the SELECT > list. It is the ORDER BY clause that is wrong. =20 > I have marked this as an regression since the error message in 10.1 is > more helpful (but still not correct): > ij> SELECT i FROM t GROUP BY i ORDER BY j; > ERROR 42Y36: Column reference 'J' is invalid. For a SELECT list with a G= ROUP BY, the list may only contain grouping columns and valid aggregate exp= ressions. --=20 This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.