Advertisement

Computer Science - Research and Development

, Volume 24, Issue 1–2, pp 37–49 | Cite as

The relational XQuery puzzle: a look-back on the pieces found so far

  • Jens TeubnerEmail author
Special Issue Paper
  • 42 Downloads

Abstract

Given the tremendous versatility of relational database implementations toward a wide range of database problems, it seems only natural to consider them as back-ends for XML data processing. Yet, the assumptions behind the language XQuery are considerably different to those in traditional RDBMSs. The underlying data model is a tree, data and results carry an intrinsic order, queries are described using explicit iteration and, after all, problems are everything else but regular.

Solving the relational XQuery puzzle, therefore, has challenged a number of research groups over the past years. The purpose of this article is to summarize and assess some of the results that have been obtained during this period to solve the puzzle. Our main focus is on the Pathfinder XQuery compiler, a full reference implementation of a purely relational XQuery processor. As we dissect its components, we relate them to other work in the field and also point to open problems and limitations in the context of relational XQuery processing.

Keywords

Relational XQuery  Relational tree encoding  XPath  Compilation  Loop lifting  Type matching 

Zusammenfassung

In Anbetracht der enormen Vielseitigkeit relationaler Datenbankimplementationen scheint es selbstverständlich, diese Systeme auch als Back-Ends für die Verarbeitung von XML einzusetzen. Jedoch unterscheiden sich die Annahmen hinter der Anfragesprache XQuery sehr deutlich von denen in strikt relationalen Systemen. Das zugrundeliegende Datenmodell ist der Baum, Daten und Ergebnisse sind inhärent geordnet, Anfragen werden formuliert mit Hilfe expliziter Iteration und die zu behandelnden Probleme sind alles andere als regulär.

Der Lösung dieses relationalen XQuery-Puzzles haben sich in den vergangenen Jahren zahlreiche Forschergruppen angenommen. Ziel dieses Artikels ist es, einige der Ergebnisse daraus zusammenzufassen und zu evaluieren. Unser Schwerpunkt wird der XQuery-Compiler Pathfinder sein, eine vollständige Referenzimplementation eines strikt relationalen XQuery-Prozessors. Während wir einzelne Komponenten von Pathfinder zerlegen, stellen wir sie in Bezug zu ähnlichen Arbeiten, zeigen dabei aber auch offene Probleme und Einschränkungen im Bereich relationaler XQuery-Verarbeitung auf.

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. 1.
    Aboulnaga A, Alameldeen AR, Naughton JF (2001) Estimating the Selectivity of XML Path Expressions for Internet Scale Applications. In: Proc. of the 27th Int’l Conference on Very Large Databases (VLDB), Rome, Italy, pp 591–600Google Scholar
  2. 2.
    Afanasiev L, Grust T, Marx M, Rittinger J, Teubner J (2008) An Inflationary Fixed Point in XQuery. In: Proc. of the 24th Int’l Conference on Data Engineering (ICDE), Cancún, MexicoGoogle Scholar
  3. 3.
    Afanasiev L, Grust T, Marx M, Rittinger J, Teubner J (2009) Recursion in XQuery: Put Your Distributivity Safety Belt On. In: Proc. 12th Int’l Conference on Extending Database Technology (EDBT), Saint Petersburg, RussiaGoogle Scholar
  4. 4.
    Al-Khalifa S, Jagadish H, Koudas N, Patel JM, Srivastava D, Wu Y (2002) Structural Joins: A Primitive for Efficient XML Query Pattern Matching. In: Proc. of the 23rd Int’l Conference on Data Engineering (ICDE), San Jose, CA, USA, pp 141–152Google Scholar
  5. 5.
    Bayer R, Unterauer K (1977) Prefix B-Trees. ACM Transactions on Database Systems (TODS) 2(1):11–26CrossRefGoogle Scholar
  6. 6.
    Boag S, Chamberlin D, Fernández MF, Florescu D, Robie J, Siméon J (2007) XQuery 1.0: An XML Query Language. World Wide Web Consortium Recommendation, http://www.w3.org/TR/xquery/ . Accessed 24 Feb 2009
  7. 7.
    Boncz P, Grust T, van Keulen M, Manegold S, Rittinger J, Teubner J (2005) Loop-Lifted Staircase Join: From XPath to XQuery. Tech. Rep. INS-E0510, CWI, AmsterdamGoogle Scholar
  8. 8.
    Boncz P, Grust T, van Keulen M, Manegold S, Rittinger J, Teubner J (2006) MonetDB/XQuery: A Fast XQuery Processor Powered by a Relational Engine. In: Proc. of the 2006 ACM SIGMOD Int’l Conference on Management of Data, Chicago, IL, USAGoogle Scholar
  9. 9.
    Boncz PA (2002) Monet: A Next-Generation DBMS Kernel for Query-Intensive Applications. PhD thesis, Universiteit van AmsterdamGoogle Scholar
  10. 10.
    Bruno N, Koudas N, Srivastava D (2002) Holistic Twig Joins: Optimal XML Pattern Matching. In: Proc. of the 2002 ACM SIGMOD Int’l Conference on Management of Data, Madison, WI, USA, pp 310–321Google Scholar
  11. 11.
    Chamberlin D, Engovato D, Florescu D, Ghelli G, Melton J, Siméon J (2008) XQuery Scripting Extension 1.0. W3C Working Draft, http://www.w3.org/TR/xquery-sx-10/ . Accessed 24 Feb 2009
  12. 12.
    Cohen E, Kaplan H, Milo T (2002) Labeling Dynamic XML Trees. In: Proc. of the 21st ACM SIGACT-SIGMOD-SIGART Symposium on Principles of Database Systems (PODS), Madison, WI, USA, pp 271–281Google Scholar
  13. 13.
    Draper D, Fankhauser P, Fernández M, Malhotra A, Rose K, Rys M, Siméon J, Wadler P (2007) XQuery 1.0 and XPath 2.0 Formal Semantics. W3C Recommendation, http://www.w3.org/TR/xquery-semantics/ . Accessed 24 Feb 2009
  14. 14.
    Fernández MF, Malhotra A, Marsh J, Nagy M, Walsh N (2007) XQuery 1.0 and XPath 2.0 Data Model (XDM). W3C Recommendation, http://www.w3.org/TR/xpath-datamodel/ . Accessed 24 Feb 2009
  15. 15.
    Florescu D, Kossmann D (1999) Storing and Querying XML Data Using an RDBMS. IEEE Data Engineering Bulletin 22(3):27–34Google Scholar
  16. 16.
    Galax (2008) Galax: An Implementation of XQuery. http://www.galaxquery.org/ . Accessed 24 Feb 2009
  17. 17.
    Galindo-Legaria CA, Joshi MM (2001) Orthogonal Optimization of Subqueries and Aggregation. In: Proc. of the 2001 ACM SIGMOD Int’l Conference on Management of Data, Santa Barbara, CA, USA, pp 571–581Google Scholar
  18. 18.
    Goldman R, Widom J (1997) DataGuides: Enabling Query Formulation and Optimization. In: Proc. of the 23rd Int’l Conference on Very Large Databases (VLDB), Athens, Greece, pp 436–445Google Scholar
  19. 19.
    Gottlob G, Koch C, Pichler R (2003) The Complexity of XPath Query Evaluation. In: Proc. of the 22nd Symposium on Principles of Database Systems (PODS), San Diego, CA, USA, pp 179–190Google Scholar
  20. 20.
    Graefe G (2003) Sorting and Indexing with Partitioned B-Trees. In: Proc. of the 1st Int’l Conference on Innovative Data Systems Research, Asilomar, CA, USAGoogle Scholar
  21. 21.
    Grust T (2002) Accelerating XPath Location Steps. In: Proc. of the 2002 ACM SIGMOD Int’l Conference on Management of Data, Madison, WI, USA, pp 109–120Google Scholar
  22. 22.
    Grust T, Teubner J (2004) Relational Algebra: Mother Tongue – XQuery: Fluent. In: Proc. of the 1st Twente Data Management Workshop (TDM), Enschede, The Netherlands, pp 7–14Google Scholar
  23. 23.
    Grust T, van Keulen M, Teubner J (2003) Staircase Join: Teach a Relational DBMS to Watch its (Axis) Steps. In: Proc. of the 29th Int’l Conference on Very Large Databases (VLDB), Berlin, Germany, pp 524–535Google Scholar
  24. 24.
    Grust T, van Keulen M, Teubner J (2004a) Accelerating XPath evaluation in any RDBMS. ACM Transactions on Database Systems (TODS) 29(1):91–131CrossRefGoogle Scholar
  25. 25.
    Grust T, Sakr S, Teubner J (2004b) XQuery on SQL Hosts. In: Proc. of the 30th Int’l Conference on Very Large Databases (VLDB), Toronto, Canada, pp 252–263Google Scholar
  26. 26.
    Grust T, Rittinger J, Teubner J (2007a) eXrQuy: Order Indifference in XQuery. In: Proc. of the 23rd Int’l Conference on Data Engineering (ICDE), Istanbul, TurkeyGoogle Scholar
  27. 27.
    Grust T, Rittinger J, Teubner J (2007b) Why Off-The-Shelf RDBMSs are Better at XPath Than You Might Expect. In: Proc. of the 2007 ACM SIGMOD Int’l Conference on Management of Data, Beijing, ChinaGoogle Scholar
  28. 28.
    Grust T, Mayr M, Rittinger J (2009) XQuery Join Graph Isolation. In: Proc. of the 25th International Conference on Data Engineering (ICDE), Shanghai, ChinaGoogle Scholar
  29. 29.
    Härder T, Haustein M, Mathis C, Wagner M (2007) Node Labeling Schemes for Dynamic XML Documents Reconsidered. Data and Knowledge Engineering 6(1):126–149CrossRefGoogle Scholar
  30. 30.
    Hidders J, Michiels P, Siméon J, Vercammen R (2007) How to Recognise Different Kinds of Tree Patterns From Quite a Long Way Away. In: Proc. of the 2007 Workshop on Programming Language Technologies for XML (PLAN-X), Nice, FranceGoogle Scholar
  31. 31.
    Josifovski V, Fontoura M, Barta A (2005) Querying XML Streams. The VLDB Journal 14(2):197–210CrossRefGoogle Scholar
  32. 32.
    Kay M (2008) The Saxon XSLT and XQuery Processor. http://saxon.sf.net/ . Accessed 24 Feb 2009
  33. 33.
    Kepser S (2004) A Simple Proof for the Turing-Completeness of XSLT and XQuery. In: Proc. of the Extreme Markup Languages 2004, Montréal, Quebec, CanadaGoogle Scholar
  34. 34.
    Koch C (2005) On the Complexity of Nonrecursive XQuery and Functional Query Languages on Complex Values. In: Proc. of the 24th Symposium on Principles of Database Systems (PODS), Baltimore, MD, USA, pp 84–97Google Scholar
  35. 35.
    Li H, Lee ML, Hsu W, Cong G (2006) An Estimation System for XPath Expressions. In: Proc. of the 22nd Int’l Conference on Data Engineering (ICDE), Atlanta, GA, USAGoogle Scholar
  36. 36.
    Marian A, Siméon J (2003) Projecting XML Documents. In: Proc. of the 29th Int’l Conference on Very Large Databases (VLDB), Berlin, Germany, pp 213–224Google Scholar
  37. 37.
    Mayer S, Grust T, van Keulen M, Teubner J (2004) An Injection with Tree Awareness: Adding Staircase Join to PostgreSQL. In: Proc. of the 30th Int’l Conference on Very Large Databases (VLDB), Toronto, Canada, pp 1305–1308Google Scholar
  38. 38.
    McHugh J, Widom J (1999) Query Optimization for XML. In: Proc. of the 25th Int’l Conference on Very Large Databases (VLDB), Edinburgh, Scotland, UK, pp 315–326Google Scholar
  39. 39.
    Michiels P, Mihaila GA, Siméon J (2007) Put a Tree Pattern in Your Algebra. In: Proc. of the 23rd Int’l Conference on Data Engineering (ICDE), pp 246–255Google Scholar
  40. 40.
    Olteanu D, Meuss H, Furche T, Bry F (2002) XPath: Looking Forward. In: XML-Based Data Management and Multimedia Engineering, EDBT 2002 Workshops, Revised Papers, Prague, Czech Republic, pp 109–127Google Scholar
  41. 41.
    O’Neil PE, O’Neil EJ, Pal S, Cseri I, Schaller G, Westbury N (2004) ORDPATHs: Insert-Friendly XML Node Labels. In: Proc. of the 2004 ACM SIGMOD Int’l Conference on Management of Data, Paris, France, pp 903–908Google Scholar
  42. 42.
    Pal S, Cseri I, Seeliger O, Rys M, Schaller G, Yu W, Tomic D, Baras A, Berg B, Churin D, Kogan E (2005) XQuery Implementation in a Relational Database System. In: Proc. of the 31st Int’l Conference on Very Large Databases (VLDB), Trondheim, Norway, pp 1175–1186Google Scholar
  43. 43.
    Park CW, Min JK, Chung CW (2002) Structural Function Inlining Technique for Structurally Recursive XML Queries. In: Proc. of the 28th Int’l Conference on Very Large Databases (VLDB), Hong Kong, China, pp 83–94Google Scholar
  44. 44.
    Polyzotis N, Garofalakis MN (2006) XSKETCH Synopses for XML Data Graphs. ACM Transactions on Database Systems (TODS) 31(3):1014–1063CrossRefGoogle Scholar
  45. 45.
    Schmidt AR, Waas F, Kersten ML, Carey MJ, Manolescu I, Busse R (2002) XMark: A Benchmark for XML Data Management. In: Proc. of the 28th Int’l Conference on Very Large Databases (VLDB), Hong Kong, China, pp 974–985Google Scholar
  46. 46.
    kx Systems (2008) The kdb+ Database. http://www.kx.com/ . Accessed 24 Feb 2009
  47. 47.
    Teubner J (2008) Scalable XQuery Type Matching. In: Proc. 11th Int’l Conference on Extending Database Technology (EDBT), Nantes, FranceGoogle Scholar
  48. 48.
    Teubner J, Grust T, Maneth S, Sakr S (2008) Dependable Cardinality Forecasts for XQuery. In: Proc. of the 34th Int’l Conference on Very Large Databases (VLDB)Google Scholar
  49. 49.
    The Pathfinder XQuery Compiler (2001–2008) http://www.pathfinder-xquery.org/ . Accessed 24 Feb 2009

Copyright information

© Springer-Verlag 2009

Authors and Affiliations

  1. 1.Systems GroupETH ZürichZürichSwitzerland

Personalised recommendations