Uploaded image for project: 'XalanJ2'
  1. XalanJ2
  2. XALANJ-1030

XPathAPI selectNodeIterator(doc, xpath) with default namespace

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Resolution: Incomplete
    • 2.3
    • None
    • XPath
    • None
    • Operating System: Windows NT/2K
      Platform: PC
    • 9339

    Description

      In xalan-j2.3.1, on Windows 2000 SP2,
      the following xpath retrieval, using the ApplyXPath example
      java ApplyXPath trydef.xml "/xxx/yyy"
      fails on the file, trydef.xml, which uses the default namespace.

      <?xml version="1.0" ?>
      <xxx xmlns="a:b//c">
      <yyy>
      <zzz aaa="333">
      </zzz>
      </yyy>
      </xxx>

      The corresponding retrieval
      java ApplyXPath trynone.xml "/xxx/yyy"
      works as expected on the file, trynone.xml, which has no namespace

      <?xml version="1.0" ?>
      <xxx>
      <yyy>
      <zzz aaa="333">
      </zzz>
      </yyy>
      </xxx>

      The corresponding retrieval using a namespace prefix also works:
      java ApplyXPath trypref.xml "/q:xxx/q:yyy"

      <?xml version="1.0" ?>
      <q:xxx xmlns:q="a:b//c">
      <q:yyy>
      <q:zzz aaa="333">
      </q:zzz>
      </q:yyy>
      </q:xxx>

      Perhaps this is related to bug #6479?

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              jgreif@alumni.princeton.edu Jeff Greif
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: