Font Size: a A A

Storing And Querying XML Documents In Relational Database

Posted on:2005-08-24Degree:MasterType:Thesis
Country:ChinaCandidate:W H DaiFull Text:PDF
GTID:2168360152469251Subject:Computer software and theory
Abstract/Summary:PDF Full Text Request
XML is quickly becoming the standard for data presentation and data exchange over the Internet. This is creating a new set of data management requirements involving XML. Combining with DM database development demand, we study the XML storing and querying technology in relational database. We suggest a new XML storing method named XNode, which is base on the face that the core of XML query is path expression comparison. Therefore, this method records the full path expression of every type of XML node, and preserves the relationship between them through a special numbering, which is described by prefix and sequence number. Ultimately XNode stores a XML document into three fixed tables in RDBMS. They are Path, Element and Data table. The Path table stores all the path expressions in XML model. The Element table stores all the information about element nodes and attribute nodes. The Data table stores the values of nodes. This method is effective on dealing with node comparison query and omitted path expression query.After the XML storing, we discuss the transformation from XML query to SQL query, which is composed of two steps. First we build XpathCore graph through XpathCore expression. In this process we concatenate the value of simple regular expression and simple absolute regular expression nodes along tree edges from the root to a node in an XpathCore graph to obtain a full path expression. Secondly we generate SQL query from an XpathCore and give the algorithm.At last we design and implement a tool used to manager XML document in DM database, which is coded by Java and named XMLDB. It is composed with two parts: XML storing module and query transform module. Storing module takes charge of parsing XML document by SAX and storing the data to XNode database through JDBC. The query transform module is charge of transforming XML query to SQL. The test result suggests XMLDB has progress in performance and universality.
Keywords/Search Tags:XML, RDBMS, XNode, query transformation
PDF Full Text Request
Related items