subqueries by semi-join like techniques21 22. Likewise, the
problem of flattening queries containing views has been a
topic of interest. The case where participating views are SPJ
queries is well understood. The problem is more complex
when one or more of the views contain aggregation23.
Naturally, this problem is closely related to the problem of
commuting group-by and join operators. However,
commuting group-by and join is applicable in the context of
single block SQL queries as well.24 25 26 An overview of the
field appears in a recent paper27.