XML Database Products:

Wrappers

Copyright 2002-2003 by Ronald Bourret

WARNING!

This list has not been updated since roughly 2010. As a result, information may be out of date and products may no longer be available. If you are interested in a product whose link does not work, search for it on the Web, as product pages frequently change and products/companies are frequently sold.

Overview

Wrappers are systems that treat XML documents as a source of relational data. (The term comes from federated database systems, where a wrapper is a component that "wraps" a source system so its data uses the model (usually relational) of a target system.) You can think of wrappers as the opposite of XML-enabled databases. That is, with wrappers, XML data is treated as relational data, while with XML-enabled databases, relational data is treated as XML data.

Wrappers can be used in a variety of situations. One common use is so that data from an XML document can be included in a heterogenous join -- that is, a SELECT statement that joins data from different systems. Another common use is for editing XML documents. Although this latter use might seem surprising, it provides developers an easy and familiar way to modify XML documents that are structured like a table.

Wrappers typically implement an SQL query engine, use an object-relational or table-based mapping, and work only with data-centric documents.

Products

Ashpool
Developer: Rob Rohan
URL: http://ashpool.sourceforge.net
License: Open Source
Direction(s): Read, write
Entry last updated: August, 2003

Ashpool is a simple relational database that uses XML documents to store data. It implements a subset of SQL by converting SQL statements into XSLT stylesheets, which are then applied to the specified XML documents. The SQL statements that are supported are SELECT, UPDATE, INSERT, DELETE, CREATE TABLE, and DROP TABLE. Ashpool does not completely implement these statements; for example, joins are not supported in SELECT statements.

Ashpool uses a table-based mapping, where each document corresponds to a single table. That is, the first three levels of an XML document are treated as table, row, and column. If an XML document contains more deeply nested markup, this is simply treated as data in a string-valued column. All of the documents used in a single session must reside in the same directory, which is specified when connecting to the database. Thus, Ashpool can be used against any XML document stored in the file system.

If an XML Schema is available for a given "table", then Ashpool enforces the rules of that schema during inserts and updates. For example, it will enforce that an input value is of the correct data type. If no XML Schema is present, then all columns will be treated as strings.

Ashpool can be run from a script or from Java using a built-in JDBC driver.
DB2 Information Integrator
Developer: IBM
URL: http://www-3.ibm.com/software/data/integration/db2ii/
License: Commercial
Direction(s): Read, write
Entry last updated: August, 2003

DB2 Information Integrator is a federated database server built on top of DB2. It can integrate data from a variety of data sources, including other relational databases, Lotus Notes, Documentum, Web services, Excel, and XML documents. Data sources are integrated through the use of "wrappers", which transfer data to and from a particular data source. Data is transferred through normal SQL statements, which are broken into sub-statements and sent to the appropriate data sources for execution.

SELECT statements can include data from multiple sources, but transactions that insert, update, or delete data can operate only against a single data source. This is because DB2 Information Integrator does not act as a transaction manager for two-phase commits.

Data in each source is mapped to a "nickname", which is equivalent to a table. Nicknames are used in SQL statements in place of table names. How data is mapped is specific to each data source.

The XML Wrapper is a wrapper for XML documents. XML documents can be mapped to one or more nicknames using an object-relational mapping. A mapping can apply to a single XML document, a directory containing XML documents, a URI that returns an XML documents, or a column in a DB2 table that contains XML documents.
SQL Server 2000
Developer: Microsoft
URL: http://msdn.microsoft.com/library/default.asp?url=/msdnmag/issues/0800/sql2000/toc.asp
License: Commercial
Direction(s): Read
Entry last updated: November, 2000

The OpenXML function in SQL Server is a wrapper. For more information, see the entry for SQL Server in XML-Enabled Databases.
Sunopsis XML Driver
Developer: Sunopsis
URL: http://www.sunopsis.com/corporate/us/products/jdbcforxml/
License: Commercial
Direction(s): Read, write
Entry last updated: May, 2002

A type 4 (all Java) JDBC driver for XML files. The Sunopsis XML Driver treats an XML document as a JDBC data source. This allows existing JDBC applications to use XML documents as data sources.

The first step to using the Sunopsis XML Driver is to associate an XML file with an in-memory structure called a schema. (The term is taken from the relational database naming hierarchy of catalog / schema / table.) Assuming there is any data in the XML file, this is loaded into memory according to an object-relational mapping. It appears that this mapping is automatic -- that is, that element and attribute names are used as table and column names and that the hierarchy of tables in the schema exactly matches the hierarchy of elements in the XML document.

Once a schema or schemas has been created, the data can be manipulated with the SQL statements SELECT, UPDATE, INSERT, and DELETE. (These commands can use data from any schema, such as to join data from two different XML documents. To identify a table in a schema other than the current schema, the application simply prepends the schema name to the table name.) It is also possible to create and drop tables. All changes occur within transactions that can be committed or rolled back. A special command, SYNCHRONIZE, is used to write changes to the in-memory structure out to the XML file and vice versa.