Alibabacloud, Database, Query Optimization, Sql, Relational Databases.
Tailoring is allowed when the output of enforcesinglerow sub-node is always one row. Some subqueries with the correlated column on the project can be rewritten as exists subqueries in some cases. sql select t1.orderkey, ( select min(t1.orderkey) from orders t2 where t2.orderkey > t1.orderkey ) from