Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 6029 invoked from network); 11 Dec 2006 08:51:15 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 11 Dec 2006 08:51:15 -0000 Received: (qmail 73246 invoked by uid 500); 11 Dec 2006 08:51:22 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 73133 invoked by uid 500); 11 Dec 2006 08:51:22 -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 73122 invoked by uid 99); 11 Dec 2006 08:51:22 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 11 Dec 2006 00:51:22 -0800 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: domain of marcin@ish.com.au designates 59.167.240.32 as permitted sender) Received: from [59.167.240.32] (HELO fish.ish.com.au) (59.167.240.32) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 11 Dec 2006 00:51:11 -0800 Received: from [10.194.9.4] (helo=[10.194.9.4]) by fish.ish.com.au with esmtp (Exim 4.43) id 1Gth6Z-0002mL-DK for derby-dev@db.apache.org; Mon, 11 Dec 2006 20:05:51 +1100 Mime-Version: 1.0 (Apple Message framework v752.2) In-Reply-To: <457C49D2.7000606@gmail.com> References: <201442F7-6995-430D-9908-4D030D8F31E5@ish.com.au> <457C49D2.7000606@gmail.com> Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <3A3CCB1E-77D1-4E22-AFD6-345040AE95FB@ish.com.au> Content-Transfer-Encoding: 7bit From: Marcin Skladaniec Subject: Re: query length Date: Mon, 11 Dec 2006 18:50:32 +1000 To: X-Mailer: Apple Mail (2.752.2) X-Spam-Score: -1.4 (-) X-Spam-Report: -1.4 ALL_TRUSTED Passed through trusted hosts only via SMTP X-Virus-Checked: Checked by ClamAV on apache.org On 11/12/2006, at 3:54 AM, Rajesh Kartha wrote: > Marcin Skladaniec wrote: > >> >> Hi ! >> I asked a question about the maximum query length on the user >> mailing list, but no one answered. >> Does someone from the dev list know the answer to my question ? >> Regards >> Marcin >> >> Begin forwarded message: >> >>> From: Marcin Skladaniec >>> Date: 6 December 2006 6:20:32 PM >>> To: derby-user@db.apache.org >>> Subject: query length >>> Reply-To: "Derby Discussion" >>> >>> hello ! >>> Is there a limit to the query length ? >>> When I execute long query (more than about 1000 characters, but >>> less than 64000) i get weird exceptions. >>> >>> Squirrel-sql reports StackOverflowError, but some exceptions >>> seems to be munched internally and never pop up, cause when not >>> using squirrel-sql I'm getting class >>> org.apache.derby.client.net.NetSqlca in response. >>> >>> Marcin >> >> >> >> > Hi Marcin, > > Some questions: > > What version of Derby are you using and what is the nature of the > query you are executing ? ~1000 characters does not > seem that long for a query, I have seen queries > 2000 characters > working in Derby > (for example http://issues.apache.org/jira/browse/DERBY-1315) > > Not sure if it is Squirrel that is causing the error, did you try > running your query using the Derby command line tool - ij ? > Is it possible to post the stack trace and a reproduction of the > issue. > > -Rajesh > Thank you for answering ! I'm using derby 10.2.1.6. I tried putting my query (about 42000 characters) to ij, as the result I got an answer : ERROR 42ZA0: Statement too complex. Try rewriting the query to remove complexity. Eliminating many duplicate expressions or breaking up the query and storing interim results in a temporary table can often help resolve this error. SQLSTATE: XBCM4: Java class file format limit(s) exceeded: method:e1 code_length (135615 > 65535) in generated class org.apache.derby.exe.ac888c4022x010fx70a9x5790xffff8e6417d30. I did simplified the query using 'SELECT * from table where field in (option1, option2 ...)' so now the query is much shorter, but I still do expect to have my query be over 10000 characters long. would that be supported ? Marcin