Problem Setting Value to an XPath containing a "+" in the XPATH Name
--------------------------------------------------------------------

                 Key: JXPATH-145
                 URL: https://issues.apache.org/jira/browse/JXPATH-145
             Project: Commons JXPath
          Issue Type: Bug
    Affects Versions: 1.3
            Reporter: Alexandre GIGLEUX


Hi,

Here is the code which fail into Exception:

{code}
    Trade trade = new Trade();
    JXPathContext ctx = JXPathContext.newContext(trade);

    ctx.setValue("keywords", new Hashtable());
    ctx.setValue("keywords/ExternalSystem", "TEST");
    ctx.setValue("keywords/A+Rate", "1.2");
{code}

When I try to set the value of "keywords/A+Rate" I get the Exception:
Exception in thread "main" org.apache.commons.jxpath.JXPathException: Exception 
trying to set value with xpath keywords/A+Rate; Cannot set value for xpath: 
keywords/A+Rate

When I change the "A+Rate" to "A-Rate". It's OK.

Is it a bug or a special feature of XPath ?

Thanks


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to