Together with groups at CWI (Amsterdam), the University of Tübingen, and the University of Konstanz, we explored how far we can push the idea of using mature relational database management technology to design and build a full-edged XML database. This allows leveraging decades of research and experience with relational databases and is expected to aid in industrial acceptance of the proposed techniques.

The tangible result of this research is MonetDB/XQuery, one of the fastest and most scalable XQuery implementations. What SQL is for relational databases, is XQuery/XQUF for XML-databases. MonetDB/XQuery provides XML database functionality comprising quite complete support for the XQuery language, including modules, transaction-safe XQUF updates, user-defined functions, and remote procedure calls (using XRPC). MonetDB/XQuery also contains PF/Tijah, which provides support for XML text search including efficient support for the W3C candidate recommendation XQuery Full-Text.

Note that, although MonetDB/XQuery is an XQuery frontend for the relational database MonetDB, the XQuery compiler, called Pathfinder, is actually re-targetable and provides a SQL code generator that allows any database to become a faithful XQuery processor.

Our approach is as follows. Pathfinder assumes the database to store shredded XML documents — documents that are transformed into a relational encoding. An XQuery is compiled by Pathfinder into an optimized relational query plan. The database evaluates the generated query plan based on the shredded XML documents and returns a table. A serializer consumes this table and transforms it into an XQuery result sequence. In MonetDB/XQuery, shredding and serialization are automatic which means that the relational approach is not visible for the end-user anymore.