|
Home > Online Product Documentation > Table of Contents > Setting the XQuery Node Data Sources Setting the XQuery Node Data SourcesAlthough the XQuery code was specified with default data sources, we want the XQuery to use the data sources we defined in the two ConvertToXML nodes we created in Configuring Data Sources. We do this by connecting the output ports on the ConvertToXML nodes to the input ports on the XQuery node. To set an XQuery node's data sources:
1. With the pointer over the
Get books catalog from txt file ConvertToXML node, drag and drop the output port on the
allBooks input port on the
Extract full order information XQuery node.
Stylus Studio creates a pipe connecting the two nodes, shown in Figure 402.
2. Repeat this procedure, connecting the output port from the
Get order from EDIFACT request ConvertToXML node to the
ediOrder input port on the
Extract full order information XQuery node.
Default and Specified Port ValuesAs you can see in Figure 402, an input port can have both a default value, and a value provided by another node's output port. Note, however, that an output port's default value is never used if a pipe is connected to the port - the pipe either supplies a value or it does not, but the default value is ignored. An Alternate Way to Create ConvertToXML Nodes
It should be noted that when you add an XQuery or an XSLT document to an XML pipeline, Stylus Studio creates other nodes required to support the resulting XQuery or XSLT node, based on the XQuery or XSLT definition. For example, since
We will see this functionality in action later, when we add another XQuery document to the XML pipeline. (See Add createReport.xquery for more information.) |
XML Schema Quality Checker
Use IBM's alphaWorks XML Schema Quality Checker to check the quality and style of your XML schema documents. Fully integrated with the Stylus Studio XML Schema Editor and XML validator.
SQL/XML Tutorial
Many developers need to be able to write applications that work for databases from multiple vendors. This SQL/XML Tutorial refers to SQL/XML, XQuery, and Native XML Programming Languages to do just that.
XQuery Debugger
The Stylus Studio XQuery Debugger allows you to set breakpoints and step through the evaluation of any XQuery expression in a way that gives you complete control and visibility into the XQuery expression evaluation process.
XML Syntax Help - Intelligent XML Editing
Stylus Studio's XML Editors feature Intelligent XML Schema/DTD-Aware Code Sensing and context sensitive XML code auto-completion. Simplify XML editing with Stylus Studio today.