Return-Path: X-Original-To: apmail-commons-user-archive@www.apache.org Delivered-To: apmail-commons-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 9AD89E91C for ; Fri, 15 Feb 2013 17:52:16 +0000 (UTC) Received: (qmail 56530 invoked by uid 500); 15 Feb 2013 17:52:15 -0000 Delivered-To: apmail-commons-user-archive@commons.apache.org Received: (qmail 56425 invoked by uid 500); 15 Feb 2013 17:52:14 -0000 Mailing-List: contact user-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Commons Users List" Delivered-To: mailing list user@commons.apache.org Received: (qmail 56417 invoked by uid 99); 15 Feb 2013 17:52:14 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 15 Feb 2013 17:52:14 +0000 X-ASF-Spam-Status: No, hits=2.2 required=5.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of Rupinder.Singh@softwareag.com designates 157.189.16.212 as permitted sender) Received: from [157.189.16.212] (HELO mailhost.softwareagusa.com) (157.189.16.212) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 15 Feb 2013 17:52:06 +0000 Received: from mailhost.softwareagusa.com (localhost [127.0.0.1]) by localhost.softwareagusa.com (Postfix) with ESMTP id E3389143BB for ; Fri, 15 Feb 2013 12:51:44 -0500 (EST) Received: from resmsg04.AME.ad.sag (resmsg04.ame.ad.sag [10.130.45.20]) by mailhost.softwareagusa.com (Postfix) with ESMTP id D5E54143B3 for ; Fri, 15 Feb 2013 12:51:44 -0500 (EST) X-MimeOLE: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----_=_NextPart_001_01CE0BA5.0B474AAE" Subject: [jxpath] Syntax with @name Date: Fri, 15 Feb 2013 12:51:07 -0500 Message-ID: <7A1775FDD530BD4F9FD43BC851FAA2190490D4CE@resmsg04.AME.ad.sag> In-Reply-To: <7CF468DE334E9444B482FF9BFB55F1E9775E3EF5@resmsg04.AME.ad.sag> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: [jxpath] Syntax with @name Thread-Index: Ac4LLlfbjPgs4HP+SG+62QkS63Qj1AAdqgGQ References: <7CF468DE334E9444B482FF9BFB55F1E9775E3EF5@resmsg04.AME.ad.sag> From: "Singh, Rupinder" To: X-Virus-Checked: Checked by ClamAV on apache.org ------_=_NextPart_001_01CE0BA5.0B474AAE Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable I have a jxpath expression question.=20 =20 Map m =3D new HashMap(); Map[] dd =3D new HashMap[2]; dd[0] =3D new HashMap(); dd[0].put("tag", "10"); dd[0].put("score", "100"); dd[1] =3D new HashMap(); dd[1].put("tag", "11"); dd[1].put("score", "90"); Map ddk =3D new HashMap(); ddk.put("dataDescription", dd); m.put("Values", ddk); =20 JXPathContext xpathContext =3D IDataJXPathContext.newContext(m); Object works =3D xpathContext.getValue("//dataDescription[tag=3D'10']"); //This returns the correct data as expected Object doesntWork =3D xpathContext.getValue("//.[@name=3D'dataDescription'][tag=3D'10']"); // = This does not bring up anything =20 =20 I have to use @name as the actual names have special characters in them. Can anybody help with what the correct syntax for this should be ? =20 Thanks =20 Rupinder =20 ------_=_NextPart_001_01CE0BA5.0B474AAE--