Return-Path: X-Original-To: apmail-chemistry-dev-archive@www.apache.org Delivered-To: apmail-chemistry-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 9F9609D26 for ; Wed, 1 Feb 2012 13:36:21 +0000 (UTC) Received: (qmail 83393 invoked by uid 500); 1 Feb 2012 13:36:21 -0000 Delivered-To: apmail-chemistry-dev-archive@chemistry.apache.org Received: (qmail 83329 invoked by uid 500); 1 Feb 2012 13:36:20 -0000 Mailing-List: contact dev-help@chemistry.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@chemistry.apache.org Delivered-To: mailing list dev@chemistry.apache.org Received: (qmail 83321 invoked by uid 99); 1 Feb 2012 13:36:20 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Feb 2012 13:36:20 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of fguillaume@nuxeo.com designates 209.85.215.42 as permitted sender) Received: from [209.85.215.42] (HELO mail-lpp01m010-f42.google.com) (209.85.215.42) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Feb 2012 13:36:16 +0000 Received: by lagk11 with SMTP id k11so1481490lag.1 for ; Wed, 01 Feb 2012 05:35:54 -0800 (PST) MIME-Version: 1.0 Received: by 10.112.31.232 with SMTP id d8mr926756lbi.96.1328103353988; Wed, 01 Feb 2012 05:35:53 -0800 (PST) Received: by 10.112.59.166 with HTTP; Wed, 1 Feb 2012 05:35:53 -0800 (PST) In-Reply-To: References: Date: Wed, 1 Feb 2012 14:35:53 +0100 Message-ID: Subject: Re: Parenthesis in query From: Florent Guillaume To: dev@chemistry.apache.org Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Yes, this is supported. You're looking at a file that walks an already-built AST to emit other stri= ngs. The grammar file you should be looking at is CmisBaseGrammar.g in the same directory. Florent On Wed, Feb 1, 2012 at 2:19 PM, Carlo Sciolla wro= te: > Hi all, > > does chemistry support parenthesis in CMIS queries? More specifically, I > need to handle a query such as > > SELECT * FROM cmis:document WHERE cmis:objectId IN (1, 2, 3) AND > (cmis:lastModifiedBy =3D 'carlo' OR cmis:createdBy =3D 'carlo') > > where the right branch of the AND clause is within parenthesis. I be migh= t > missing something here, but it seems to me that the current > grammarresults > in parens to be swallowed in the parsing process, and not visible > in the resulting parsed tree. > > Any idea on this? > > Thanks, > c. > > -- > Carlo Sciolla > > --=3D=3D(A)=3D=3D-- > Linux User #372086 > My personal blog: http://www.skuro.tk > Follow me on twitter: http://twitter.com/skuro > Fork me on Github: http://github.com/skuro > =C2=A0My LinkedIn profile: > http://nl.linkedin.com/in/carlosciolla > --=3D=3D(A)=3D=3D-- > > Senior Developer at Backbase - Next Generation Portal Software for > Financials & Large Enterprises (http://www.backbase.com) --=20 Florent Guillaume, Director of R&D, Nuxeo Open Source, Java EE based, Enterprise Content Management (ECM) http://www.nuxeo.com=C2=A0=C2=A0 http://www.nuxeo.org=C2=A0=C2=A0 +33 1 40 = 33 79 87