XML database

XML database

An XML database is a data persistence software system that allows data to be stored in XML format. This data can then be queried, exported and serialized into the desired format.

Two major classes of XML database exist:

  1. XML-enabled: these map all XML to a traditional database (such as a relational database[1]), accepting XML as input and rendering XML as output. This term implies that the database does the conversion itself (as opposed to relying on middleware).
  2. Native XML (NXD): the internal model of such databases depends on XML and uses XML documents as the fundamental unit of storage, which are, however, not necessarily stored in the form of text files.

Contents

Rationale for XML in databases

O'Connell (2005, 9.2) gives one reason for the use of XML in databases: the increasingly common use of XML for data transport, which has meant that "data is extracted from databases and put into XML documents and vice-versa". It may prove more efficient (in terms of conversion costs) and easier to store the data in XML format.

Native XML databases

The term "native XML database" (NXD) can lead to confusion. Many NXDs do not function as standalone databases at all, and do not really store the native (text) form.

The formal definition from the XML:DB initiative (which appears to be inactive since 2003[2]) states that a native XML database:

  • Defines a (logical) model for an XML document — as opposed to the data in that document — and stores and retrieves documents according to that model. At a minimum, the model must include elements, attributes, PCDATA, and document order. Examples of such models include the XPath data model, the XML Infoset, and the models implied by the DOM and the events in SAX 1.0.
  • Has an XML document as its fundamental unit of (logical) storage, just as a relational database has a row in a table as its fundamental unit of (logical) storage.
  • Need not have any particular underlying physical storage model. For example, NXDs can use relational, hierarchical, or object-oriented database structures, or use a proprietary storage format (such as indexed, compressed files).

Additionally, many XML databases provide a logical model of grouping documents, called "collections". Databases can set up and manage many collections at one time. In some implementations, a hierarchy of collections can exist, much in the same way that an operating system's directory-structure works.

All XML databases now support at least one form of querying syntax. Minimally, just about all of them support XPath for performing queries against documents or collections of documents. XPath provides a simple pathing system that allows users to identify nodes that match a particular set of criteria.

In addition to XPath, many XML databases support XSLT as a method of transforming documents or query-results retrieved from the database. XSLT provides a declarative language written using an XML grammar. It aims to define a set of XPath filters that can transform documents (in part or in whole) into other formats including Plain text, XML, or HTML.

Many XML databases also support XQuery to perform querying. XQuery includes XPath as a node-selection method, but extends XPath to provide transformational capabilities. Users sometimes refer to its syntax as "FLWOR" (pronounced 'Flower') because the query may include the following clauses: 'for', 'let', 'where', 'order by' and 'return'. Traditional RDBMS vendors (who traditionally had SQL only engines), are now shipping with hybrid SQL and XQuery engines. Hybrid SQL/XQuery engines help to query XML data alongside the relational data, in the same query expression. This approach helps in combining relational and XML data.

Some XML databases support an API called the XML:DB API (or XAPI) as a form of implementation-independent access to the XML datastore. In XML databases, XAPI resembles ODBC and JDBC as used with relational databases. On the 24th of June 2009, The Java Community Process released the final version of the XQuery API for Java specification (XQJ) - "a common API that allows an application to submit queries conforming to the W3C XQuery 1.0 specification and to process the results of such queries".

XML Databases with database APIs (XQJ, XML:DB, RESTful)

XML Database License Language XQJ API XML:DB API RESTful API
BaseX BSD License Java Yes Yes Yes
eXist LGPL License Java Yes Yes Yes
MarkLogic Server Commercial C++ Yes No Yes
MonetDB/XQuery Proprietary C++ No Yes No
Oracle Commercial C++ Yes No No
Sedna Apache License C++ Yes Yes No

References

  1. ^ Mustafa Atay and Shiyong Lu, “Storing and Querying XML: An Efficient Approach Using Relational Databases”, ISBN 3-639-11581-3, VDM Verlag, 2009.
  2. ^ http://xmldb-org.sourceforge.net/faqs.html

External references


Wikimedia Foundation. 2010.

Игры ⚽ Нужен реферат?

Look at other dictionaries:

  • XML Certification Program — (XML Master) is IT professional certification for XML and related technologies. There are two levels of XML Certifications, XML Master Basic certification and XML Master Professional certification, and more than 16000 examiners have passed those… …   Wikipedia

  • XML framework — is a Software framework. Basically the framework implement several features to aid the programmer create your own application, but an XML framework differs from another framework because all data produced is XML. The programmer define and… …   Wikipedia

  • Database — A database is an organized collection of data for one or more purposes, usually in digital form. The data are typically organized to model relevant aspects of reality (for example, the availability of rooms in hotels), in a way that supports… …   Wikipedia

  • XML-Datenbank — Als XML Datenbank werden Datenbanken oder Datenbankverwaltungssysteme bezeichnet, die Daten im XML Format speichern oder anderweitig mit XML Daten umgehen können. Man kann daher XML Datenbanksysteme in zwei Kategorien unterteilen: XML enabled:… …   Deutsch Wikipedia

  • Database model — A database model is the theoretical foundation of a database and fundamentally determines in which manner data can be stored, organized, and manipulated in a database system. It thereby defines the infrastructure offered by a particular database… …   Wikipedia

  • Database system — A database system is a term that is typically used to encapsulate the constructs of a data model, database Management system (DBMS) and database.[1] A database is an organised pool of logically related data. Data is stored within the data… …   Wikipedia

  • XML Schema — XML Schema, abgekürzt XSD, ist eine Empfehlung des W3C zum Definieren von Strukturen für XML Dokumente. Anders als bei den klassischen XML DTDs wird die Struktur in Form eines XML Dokuments beschrieben. Darüber hinaus wird eine große Anzahl von… …   Deutsch Wikipedia

  • XML Base — ist eine vom World Wide Web Consortium empfohlene Möglichkeit, Basis URLs für Teile von XML Dokumenten zu definieren. Basis URL bezeichnet dabei diejenige URL, von der aus relative Pfadangaben im Dokument aufgelöst werden. Die XML Base Empfehlung …   Deutsch Wikipedia

  • XML Events — ist eine Spezifikation des W3C, um Ereignisse, die in einem XML Dokument auftreten, zu handhaben. Diese Ereignisse werden typischerweise durch einen Benutzer ausgelöst, der mit dem Dokument, einer Webseite, mit Hilfe eines Internetbrowsers auf… …   Deutsch Wikipedia

  • XML-binary Optimized Packaging — (XOP) ist eine W3C Empfehlung für die Repräsentation binärer Daten in XML Dokumenten. XOP ersetzt damit die sonst für die Repräsentation binärer Daten in XML Dokumenten üblichen Techniken wie Verwendung von CDATA Blöcken, Base64 Kodierung, SOAP… …   Deutsch Wikipedia

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”