Use a materialized view in a subquery
You can create a materialized view for optimizing a subquery.
In this task, you create a materialized view and use it in a subquery to return the
number of destination-origin pairs. Suppose the data resides in a table named
flights_hdfs that has the following data:| c_id | dest | origin |
|---|---|---|
| 1 | Chicago | Hyderabad |
| 2 | London | Moscow |
| ... |

