- We will update you soon with information on how we proceed during the corona virus teaching suspension. You may want to track changes to this website, so you know when new information is available. Consider a tool like https://sken.io/ .
- Please send Magnus an email, so he knows how to get in touch with you.
- After the teaching suspension, the exercise sessions take place on Tuesdays 15:30-17:00 (rescheduled from Wed 13:45-15:15).
|Lecturer:||Prof. Dr. Guido Moerkotte|
|Credit:||6 ECTS (4SWS)|
|Time and place:||Tues. 13:45-15:15, B 6 A 303|
|First time:||See Portal|
Note: As announced in the lecture, the first exercise session takes place March 4th.
Query optimization is a function of many relational database management systems. The query optimizer attempts to determine the most efficient way to execute a given query by considering the possible query plans.
A query is a request for information from a database. It can be as simple as „finding the address of a person with SS# 123-45-6789,“ or more complex like „finding the average salary of all the employed married men in California between the ages 30 to 39, that earn less than their wives.“
Queries results are generated by accessing relevant database data and manipulating it in a way that yields the requested information. Since database structures are complex, in most cases, and especially for not-very-simple queries, the needed data for a query can be collected from a database by accessing it in different ways, through different data-structures, and in different orders. Each different way typically requires different processing time. Processing times of the same query may have large variance, from a fraction of a second to hours, depending on the way selected.
The purpose of query optimization, which is an automated process, is to find the way to process a given query in minimum time. The large possible variance in time justifies performing query optimization, though finding the exact optimal way to execute a query, among all possibilities, is typically very complex, time consuming by itself, may be too costly, and often practically impossible. Thus query optimization typically tries to approximate the optimum by comparing several common-sense alternatives to provide in a reasonable time a „good enough“ plan which typically does not deviate much from the best possible result.
In this lecture we discuss join ordering, usage of index structures, subquery unnesting, and basic formulas for cost estimation.
Knowledge in Database Systems and Algorithms.
|Time and place:||Tues. 15:30-17:00, B6 A 303|
|First time:||See Portal|
- The exercise sessions are rescheduled for Tuesday 15:30-17:00 (starting after teaching suspension due to the Corona virus).
- If you're interested in C++ programming, I highly recommend attending the first exercise sessions in DBSII.
- If you are interested in Go programming, this 1h video and this tutorial might be a good entry point.
- See these slides https://db.in.tum.de/teaching/ws1819/queryopt/exercises/session5.pdf (starting at pdf-page 14) for a good discussion on IKKBZ. See here for another example run pdf.