Title: Theory / Unimportant / CS / Programming / Sql / Optimization

Name: Decorelation
Definition: Rewritting a query so that its subquery do not make reference to outer query
Context: SQL
Example: SELECT R.a FROM R WHERE R.b IN (SELECT S.b from S)
Intuition: the subquery can be considered as a view, hence computed once a single time
Applied to: SELECT R.a FROM R WHERE EXISTS (SELECT * FROM S WHERE R.b = S.b)