...
Table of Content Zone | |||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| |||||||||||||||||||||
This section provides an introduction to Hive materialized views syntax. More information about materialized view support and usage in Hive can be found here. Create Materialized View
CREATE MATERIALIZED VIEW creates a view with the given name. An error is thrown if a table, view or materialized view with the same name already exists. You can use IF NOT EXISTS to skip the error. The names of the materialized view's columns will be derived automatically from the defining SELECT expression. A CREATE MATERIALIZED VIEW statement will fail if the view's defining SELECT expression is invalid.
Drop Materialized View
DROP MATERIALIZED VIEW removes metadata and data for this materialized view. Alter Materialized ViewOnce a materialized view has been created, the optimizer will be able to exploit its definition semantics to automatically rewrite incoming queries using materialized views, and hence, accelerate query execution. Users can selectively enable/disable materialized views for rewriting. Recall that, by default, materialized views are enabled for rewriting at creation time. To alter that behavior, the following statement can be used:
|
...