ABSTRACT
Many enterprise applications prefer to store XML data as a rich data type, i.e. a sequence of bytes, in a relational database system to avoid the complexity of decomposing the data into a large number of tables and the cost of reassembling the XML data. The upcoming release of Microsoft's SQL Server supports XQuery as the query language over such XML data using its relational infrastructure.XQuery is an emerging W3C recommendation for querying XML data. It provides a set of language constructs (FLWOR), the ability to dynamically shape the query result, and a large set of functions and operators. It includes the emerging W3C recommendation XPath 2.0 for path-based navigational access. XQuery's type system is compatible with that of XML Schema and allows static type checking.This paper describes the experiences and the challenges in implementing XQuery in Microsoft's SQL Server 2005. XQuery language constructs are compiled into an enhanced set of relational operators while preserving the semantics of XQuery. The query tree is optimized using relational optimization techniques, such as cost-based decisions, and rewrite rules based on XML schemas. Novel techniques are used for efficiently managing document order and XML hierarchy.
References
- B. Beauchemin, N. Berglund, D. Sullivan. A First Look at Microsoft SQL Server 2005 for Developers. Addison-Wesley, 2004. Google Scholar
Digital Library
- J. Cowan, R. Tobin, eds. XML Information Set. http://www.w3.org/TR/2001/WD-xml-infoset-20010316.Google Scholar
- Extensible Markup Language (XML) 1.0. http://www.w3.org/TR/REC-xml.Google Scholar
- M. Fernandez, Y. Kadiyska, A. Morishima, D. Suciu, W-C Tan. SilkRoute: a framework for publishing relational data in XML. ACM TODS, vol. 27, no. 4, December, 2002. Google Scholar
Digital Library
- D. Florescu et al. The BEA/XQRL Streaming XQuery Processor. VLDB Conference, 2003. Google Scholar
Digital Library
- C. Galindo-Legaria, M. Joshi. Orthogonal Optimization of Subqueries and Aggregation. SIGMOD 2001. Google Scholar
Digital Library
- T. Grust, S. Sakr, J. Teubner. XQuery on SQL Hosts. VLDB Conference, 2004. Google Scholar
Digital Library
- J. Melton. ISO/IEC 9075-14:2003, Information technology --- Database languages --- SQL --- Part 14: XML-Related Specifications (SQL/XML), 2004.Google Scholar
- Microsoft .NET framework. http://msdn.microsoft.com/netframework.Google Scholar
- Microsoft SQL Server#8482;. http://www.microsoft.com/sql.Google Scholar
- P. O'Neil, E. O'Neil, S. Pal, I. Cseri, G. Schaller. ORDPATHs: Insert-Friendly XML Node Labels. SIGMOD 2004. Google Scholar
Digital Library
- S. Pal, I. Cseri, O. Seeliger, G. Schaller, L. Giakoumakis, V. Zolotov. Indexing XML Data Stored in a Relational Database. In Proceedings of VLDB Conference, Toronto, 2004. Google Scholar
Digital Library
- S. Pal, M. Fussell, I. Dolobowsky. XML support in Microsoft SQL Server 2005. MSDN Online, http://msdn.microsoft.com/xml/default.aspx?pull=/library/en-us/dnsq190/html/sql2k5xml.asp, 2004.Google Scholar
- S. Pal, V. Parikh, V. Zolotov, L. Giakoumakis, M. Rys. XML Best Practices for Microsoft SQL Server 2005. MSDN Online, http://msdn.microsoft.com/xml/default.aspx?pull=/library/en-us/dnsq190/html/sql25xmlbp.asp, 2004.Google Scholar
- M. Rys. XQuery and Relational Database Systems. In XQuery from the Experts, Howard Katz (ed.), Addison-Wesley, 2003.Google Scholar
- M. Rys. XQuery in Relational Database Systems. XML 2004 Conference, Washington DC, Nov 2004. http://www.idealliance.org/proceedings/xml04/abstracts/paper254.html.Google Scholar
- J. Shanmugasundaram, R. Krishnamurthy. I. Tatarinov. A General Technique for Querying XML Documents using a Relational Database System. SIGMOD 2001. Google Scholar
Digital Library
- I. Tatarinov, E. Viglas, K. Beyer, J. Shanmugasundaram, E. Shekita. Storing and Querying Ordered XML Using a Relational Database System. SIGMOD 2002. Google Scholar
Digital Library
- XML Path Language (XPath) 1.0. http://www.w3.org/TR/xpath, 1999.Google Scholar
- XML Path Language (XPath) 2.0. http://www.w3.org/TR/2003/WD-xpath20-20031112, 2003.Google Scholar
- XML Schema Part 1: Structures and Part 2: Datatypes. W3C Recommendation 2 May 2001. http://www.w3.org/TR/2001/REC-xmlschema-1-20010502, http://www.w3.org/TR/2001/REC-xmlschema-2-20010502.Google Scholar
- XQuery 1.0: An XML Query Language. http://www.w3.org/TR/xquery.Google Scholar
- XQuery 1.0 and XPath 2.0 Data Model. http://www.w3.org/TR/2005/WD-xpath-datamodel-20050211.Google Scholar
Index Terms
XQuery implementation in a relational database system




Comments