134 The XML Files: Develo pment of XML/XSL Applications Using WebS phere Studio
Figure 6-14 XM L Column method over view
6.4.1 XML Collection
The XML Coll ection refers to a set of tables that is mappe d to XML documents.
This method is used to decompose the incom ing XML document into database
table columns or compose XML document from the data in database tables.
The XML Collection is defined in a DAD file, which specifies how the elements or
attributes of an XML document are mapped to one or more tables. The collection
is given a name so that it is easily run with stored procedures when composing or
decomposing the XML documents.
The tables can be a new set of tables that the XML Extender creates based on
the DAD file, when decomposing the XML document, or existing set of tables that
were used to compose the XML document. Columns of these tables are mapped
to the elements or attributes of the XML data. The data in these table columns
does not contain XML tags; it contains the content of the element and the values
of the attributes in the XML document. Figure 5-7 gives an overview of XML
collection.
XML Column Method OverviewXML Column MethodDocument insert, update, delete, search & retrieve
(UDFs and Stored Procedures)

XML

Documents

Application

DB2 XML ExtenderXML Side Tables
XML_USAGE
DAD
DTD_REF
DTD User Tables
"as is" xml document
xmlClob or
xmlVarchar
data-type
elements/attributes