Abstract. Enterprise information systems (EIS) often employ relational database systems to store their content. At the same time, XML constitutes the dominant standard for data exchange as well as for the hypertext level of webenabled EIS. Thus, the integration of XML with relational database systems to allow the storage, retrieval, and update of XML documents is of paramount importance in the context of EIS. Data model heterogeneity and schema heterogeneity, however, make this a challenging task. This paper proposes XRay, a generic approach facilitating the composition of XML documents out of a relational database system as well as the decomposition of XML documents to store them within a relational database system in a fully transparent way. This is achieved by means of a generic meta schema that stores all relevant information for the composition and decomposition process. This meta schema covers both, the concepts of DTDs and XML Schema concepts.