Q&A
Is XQuery supported in any web browsers?
Not yet. Unfortunately, none of the major browsers support XQuery just yet, although rumors abound that XQuery support is underway for upcoming releases.
How does XQuery differ from XPath?
XPath is a language used for addressing within XML documents. XQuery is a query language used to filter data within XML documents. XPath can also be used for pattern matching on XML documents and in fact serves that role within XQuery. Fundamentally, the two languages differ more in purpose than in design. XQuery solves a larger problem and incorporates XPath toward that end. Addressing and Linking XML Documents covers XPath in detail.
Workshop
The Workshop is designed to help you anticipate possible questions, review what you've learned, and begin learning how to put your knowledge into practice.
Quiz
1. |
How do the queries |
2. |
How do you indicate that a query entity is an attribute rather than an element? |
3. |
How do you embed query results within other XML code? |
Quiz Answers
1. |
The first of the two queries returns |
2. |
Names that begin with |
3. |
Enclose the query results in |
Exercises
1. |
Download an implementation of XQuery, such as Saxon, and use it to write some queries against your own XML documents. You can download a free open source version of Saxon from |