Using the collection() Function in Stylus Studio

The process of using the collection() function in Stylus Studio consists of these basic steps:

1. Create a connection to the database server whose tables and/or views you want to query. You create database connections from the File Explorer window.
2. Register the database connection with your XQuery document. This process allows the database's tables and views to be used in your XQuery code.
3. Invoke the collection() function in your XQuery code. You can type the collection() statement by hand, or have Stylus Studio create it for you.
4. Ensure that the processor specified in the XQuery scenario is either the Stylus Studio built-in processor or the DataDirect XQuery processor.

These steps are described in greater detail later in this section.

 
Free Stylus Studio XML Training: