Received: from localhost (unknown [200.46.204.182]) by postgresql.org (Postfix) with ESMTP id B578E9FC1AA for ; Thu, 18 Oct 2007 13:27:47 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.182]) (amavisd-maia, port 10024) with ESMTP id 99541-03 for ; Thu, 18 Oct 2007 13:27:44 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from mail.gmx.net (mail.gmx.net [213.165.64.20]) by postgresql.org (Postfix) with SMTP id 2A49A9FBCE0 for ; Thu, 18 Oct 2007 13:27:43 -0300 (ADT) Received: (qmail invoked by alias); 18 Oct 2007 16:27:42 -0000 Received: from office01.emerion.com (EHLO [192.168.1.150]) [83.64.50.26] by mail.gmx.net (mp054) with SMTP; 18 Oct 2007 18:27:42 +0200 X-Authenticated: #1946847 X-Provags-ID: V01U2FsdGVkX18m1utl9eUmVkAV/wbajMRFjVEsP14EstNpnNAFpK VjDFM17U1J7fpz Message-ID: <4717897C.8070909@gmx.at> Date: Thu, 18 Oct 2007 18:27:40 +0200 From: Michael Paesold User-Agent: Thunderbird 1.5.0.12 (X11/20070719) MIME-Version: 1.0 To: Michael Paesold CC: Kris Jurka , Tom Lane , Altaf Malik , pgsql-jdbc@postgresql.org Subject: Re: Unable to prepare a statement when the object names contain more than one $ symbol References: <540504.87872.qm@web39103.mail.mud.yahoo.com> <23286.1183999558@sss.pgh.pa.us> <46937FCD.7060409@gmx.at> <4714DDF1.9020403@gmx.at> <47177F0E.6020601@gmx.at> In-Reply-To: <47177F0E.6020601@gmx.at> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200710/93 X-Sequence-Number: 17665 I wrote: ... > 1) In parseDollarQuotes(), we look at the character directly before the > $-char and compare it against all valid identifier characters. If it is, > we don't have a possible dollar-quote start: > > From scan.l: > ident_start [A-Za-z\200-\377_] > ident_cont [A-Za-z\200-\377_0-9\$] ... > Looking at gram.y and scan.l (...but I'm no expert) I can't see another > case of a dollar-character that I missed, except the one allowed in > ident_cont... so option 1) seems like the easiest solution. I will send > a patch implementing option 1 shortly. Ok, here is the patch. It also adds your tests exposing the bug to the test suite. The patch fixes both test cases and passes all other regression tests (at least with JDK 1.5....). Does it look OK to you? Should we do anything additional about error-ing out when we detect an unterminated dollar-quote (see previous mail)? Best Regards Michael Paesold