Uploaded image for project: 'ODE'
  1. ODE
  2. ODE-1027

Variables as number predicates don't work with XPath 1.0

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 1.3.6
    • 1.3.7, 1.4
    • BPEL Runtime
    • None

    Description

      When variables are used as number predicates to select a specific node, in XPath 1.0 the variable value is treated as string and not properly casted to a number. Thus, Jaxen will select all nodes and not a single node. This can be fixed by added a special cast to org.apache.ode.bpel.elang.xpath10.runtime.JaxenContexts.getVariableValue(String, String, String) – in the same way as Booleans are treated.

      As a workaround, the variable can be casted in the XPath expression itself, so instead of tns:args[$Counter]/tns:name you can write tns:args[number($Counter)]/tns:name.

      Attachments

        Activity

          People

            vanto Tammo van Lessen
            vanto Tammo van Lessen
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: