XML Query
1 posts in topic
Flat View  Flat View

Posted By:   Corina_Stefan
Posted On:   Thursday, April 26, 2001 11:09 AM


How can I query my xml file? For example I have this xml file:

<?xml version="1.0"?>


Harold's Fairy Tale

and I want to display the result of "author where title = 'Harold'".
How should I write the query and where I should put it, in another xml file? or html file?

Re: XML Query

Posted By:   Chris_Leonardi  
Posted On:   Tuesday, May 1, 2001 08:30 PM

XPath provides a means of querying down into XML documents:


Look at 'Location Paths' for the syntax relevant to your particular query.

Apache Xalan implements the XPath 1.0 recommendation:


Typically, you'd write a XSL styelsheet that uses an XPath expression to traverse your document tree and select the appropriate nodes.

You can also use xpath programatically from a Java class; Xalan provides an API for that, too.
About | Sitemap | Contact