Explicitly Specifying the Current Context

If you want to explicitly specify the current context node, place a dot and a forward slash ( ./) in front of the query. This construct typically appears in queries that contain filters . The following two queries are equivalent:

./author 
               
author
               

            

Remember, if you specify the name of an element as a complete query (for example, foo), you obtain only the foo elements that are children of the current context node. You do not necessarily obtain all foo elements in the document.

You can also specify the dot notation ( .) to indicate that you want the XPath processor to manipulate the current context. For example:

//title [. = "History of Trenton"]
               

            

In this example, the XPath processor finds all title elements. The dot indicates the context node. This causes the XPath processor to check each title in turn to determine whether its string value is History of Trenton.

EAI - Enterprise Application Integration

Using EAI tools included with Stylus Studio it's easy to unlock silos of enterprise data and seamlessly integrate it into your IT applications.

SQL Server Tools

Integrated SQL Server Tools in Stylus Studio enable you to access relational data stored in SQL Server 2000 or SQL Server 2005 as XML using XQuery, SQL/XML or ADO - learn how to export relational data as XML today!

XML Schema Designer

The XML Schema Designer is a tool for accelerating advanced XML Schema development through an intuitive visual interface for modeling any XML data structures.

Text File to XML

Stylus Studio provides several easy-to-use document wizards that allow you to quickly convert text files to XML. Create XML from text and EDI, create XML Schema from EDIFACT, and more!

Stylus Most Wanted

 
Free Stylus Studio XML Training:
W3C Member