With the IBM Database Add-Ins for Visual Studio, you can store an XML document in a column of a relational database as a data type XML. You can also extract data from XML documents and store the data in columns in a relational database. The extraction process is referred to as decomposition.
You specify how to decompose the data in an XML document by creating map links in an XML schema. A map link defines the association between an element or attribute in the XML schema and a column in a database table. The properties associated with each map link contain the information that describes how to process the data that is associated with that element or attribute in an XML document.
An XML schema that contains map link information is referred to as an annotated XML schema. You can use the IBM XML Schema Mapping Designer to create annotated XML schemas.
After you have created an annotated XML schema, you can test whether you have specified your map links correctly. The test runs the DB2 decomposition stored procedure named SYSPROC.XDBDECOMPXML, which uses the annotated XML schema to extract data from an XML document that you specify.
If the test runs successfully, you can then use SYSPROC.XDBDECOMPXML to extract data items from XML documents and populate those data items into columns of relational tables. For information about how to use the SYSPROC.XDBDECOMPXML decomposition stored procedure, refer to your DB2 documentation.
Annotating XML Schemas | IBM XML Schema Mapping Designer