Database Related – While discussing database related facets, it is good
to remember the following natural components and relations in object oriented
XML applications.

Figure 2: Database / XML / Object Relationships Looking at the associations
in some detail we have:
- Database to/fro XML: Most non-native-XML databases provide programmatic XML export/import functionality to read XML file data into the database and write out database data into XML documents. This is usually done by some form or middleware.
- Database to/fro Program Objects: In order to transfer data from database to program objects and vice versa, often the concept of Object Relational (OR) Mapping is used. OR mapping is essentially the process of transforming between object and relational modeling approaches and between the applications that support those approaches.
- XML Documents to/fro Program Objects: This process refers to the task of reading an XML document and splitting it up into logical entities that can eventually become OO programming language objects (and the reverse). There are two distinct approaches to doing this. In one, the XML DTD or Schema itself provides the class definition and a mapping is done. These are called mapped bindings. In the other, the class definition is automatically generated from the content itself. These are called generated bindings. In both cases of course, the XML contents are parsed into actual object instances.