Abstract
The query-tree class shown in Chapter 12 forms the starting point for building the experimental-query optimization and execution engine for DBXP. In this chapter, I show you how to add the optimizer to the query-tree class. I begin by explaining the rationale for the heuristics (or rules) used in the optimizer and then jump into writing the code. Because the code for some of the functions is quite lengthy, the examples in this chapter are excerpts. If you are following along by coding the examples, download the source code for this chapter instead of typing in the code from scratch.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
References
P. G. Selinger, M. M. Astraham, D. D. Chamberlin, R. A. Lories, and T. G. Price. 1979. “Access Path Selection in a Relational Database Management System”. Proceedings of the ACM SIGMOD International Conference on the Management of Data, Aberdeen, Scotland: 23–34. Considered by some to be the “Bible of Query Optimization.”
M. Stonebraker, E. Wong, P. Kreps. 1976. “The Design and Implementation of INGRES.” ACM Transactions on Database Systems 1(3): 189–222.
D. Kossman and K. Stocker. 2000. “Iterative Dynamic Programming: A New Class of Query Optimization Algorithms.” ACM Transactions on Database Systems 25(1): 43–82.
Y. E. Ioannidis, R. T. Ng, K. Shim, and T. Sellis. 1997. “Parametric Query Optimization.” VLDB Journal 6:132–151.
C. Lee, C. Shih, and Y. Chen. 2001. “A Graph-Theoretic Model for Optimizing Queries Involving Methods.” VLDB Journal 9:327–343.
Rights and permissions
Copyright information
© 2012 Charles Bell
About this chapter
Cite this chapter
Bell, C. (2012). Query Optimization. In: Expert MySQL. Apress, Berkeley, CA. https://doi.org/10.1007/978-1-4302-4660-2_13
Download citation
DOI: https://doi.org/10.1007/978-1-4302-4660-2_13
Publisher Name: Apress, Berkeley, CA
Print ISBN: 978-1-4302-4659-6
Online ISBN: 978-1-4302-4660-2
eBook Packages: Professional and Applied ComputingProfessional and Applied Computing (R0)Apress Access Books