You are viewing a plain text version of this content. The canonical link for it is here.
Posted to xindice-users@xml.apache.org by "Wang, XD (Xiao Dong)" <X....@dl.ac.uk> on 2003/03/21 10:48:06 UTC

XPath problem of XML Prefix

Hi there

I have put a xml file in /db/person.

<?xml version="1.0"?>
<ns1:Person xml:ns1="http://namespace.org">
   <PersonDN>DN string</PersonDN>
   <PersonDescription>
      <Name>person name</Name>
      <Status>PDRA</Status>
      <ShortDescription>desc string</ShortDescription>
   </PersonDescription>
</ns1:Person>

  
When I query Xindice with:

xindice xpath -c /db/person -q /ns1:Person

An Exception happens like below,

DEBUG> javax.xml.transform.TransformerException: Extra illegal tokens: ':',
'Person'

If I remove the prefix ns1:, then it works.

Anyone knows what is going on and how to fix it?

ciao

Xiaodong