XQuery multiple xml files? -


Is it possible to open and attach 2 documents with Exclose?

<

Yes, from here.

", which combines data from many, the source is a very important type of query in the same result. In this section, we will explain how many types of XQuery We can base our examples on the following examples:

  1. parts.xml contains a number of part element; Each part element is changed to partno and details Subscriptions.
  2. A document named suppliers.xml has many suppliers elements; Each supplier component in return < Code> suppno and suppname are subelements.
  3. A document named catalog.xml in which information about relationships between suppliers and parts In the catalogs document there are many items elements, each of which alternately in partno , suppno , and values contains subelements.

A traditional ("internal") gives information from two or more related sources, as explained by the following example, which adds information to three documents. The example catalog generates a "descriptive list" derived from the document, but instead of the supplier numbers, the part includes details of the number and instead of the supplier names. The new catalog is ordered alphabetically according to the details of the part and the second thing has been sorted by the supplier name. *

  & lt; Descriptive-list & gt; {$ I fn: doc ("catalog.xml") / item / item, $ p fn: doc ("parts.xml") / parts / section [partno = $ i / partno], $ s in fn: document ("Suppliers.exml") / Suppliers / Suppliers [suppno = $ i / suppno] $ p / order by order, $ s / suppname return & lt; Item & gt; {$ P / Description, $ s / suppname, $ i / price} & lt; / Item & gt; } & Lt; / Descriptive-catalogs & gt;  

The previous query only provides information about parts that have suppliers and suppliers have a external interaction which is one or more interactive sources Protects information from, which does not have any matching element in other sources. For example, between a suppliers and parts, a left external participant can return information about suppliers who have no matching part. "

Note that XQuery does not have a standard document () function (this is the one) and instead is a function, which is a part of" ".

There are at least two errors in response to Chris

  1. XQuery - The capitalization keyword used in Chris is in a favorable XQuery will not be allowed by the processor.
  2. Standard work is not necessary, such as the Doctor (), I only have Exquity Otherwise, in my code I have the prefix " fn ".
  3. Function document () A standard XQuery / XPath function < / Strong>. Function should be used instead.

Comments