Alibabacloud, Database, Query Optimization, Sql, Relational Databases.
connect the subquery results to the external query, when the external query contains all the tables and conditions in the subquery. It is helpful for saving a lot of tablescan operations. Take the rewriting of tpch q2 as an example, as shown in the following figure. Agg can be rewritten as window