バージョンごとのドキュメント一覧

DROP MATERIALIZED VIEW

DROP MATERIALIZED VIEW <refpurpose>remove a materialized view</refpurpose> — マテリアライズドビューを削除する

概要

DROP MATERIALIZED VIEW [ IF EXISTS ] name [, ...] [ CASCADE | RESTRICT ]

説明

<title>Description</title>

<command>DROP MATERIALIZED VIEW</command> drops an existing materialized view. To execute this command you must be the owner of the materialized view. DROP MATERIALIZED VIEWは既存のマテリアライズドビューを削除します。 このコマンドを実行するためにはマテリアライズドビューの所有者でなければなりません。

パラメータ

<title>Parameters</title>
IF EXISTS

Do not throw an error if the materialized view does not exist. A notice is issued in this case. マテリアライズドビューが存在しない場合でもエラーを発生しません。 この場合注意が発生します。

name

The name (optionally schema-qualified) of the materialized view to remove. 削除対象のマテリアライズドビューの名前(スキーマ修飾可)です。

CASCADE

Automatically drop objects that depend on the materialized view (such as other materialized views, or regular views), and in turn all objects that depend on those objects (see <xref linkend="ddl-depend"/>). マテリアライズドビューに依存するオブジェクト(他のマテリアライズドビューや通常のビューなど)を自動的に削除し、さらにそれらのオブジェクトに依存するすべてのオブジェクトも削除します(5.14参照)。

RESTRICT

Refuse to drop the materialized view if any objects depend on it. This is the default. 依存するオブジェクトがある場合にマテリアライズドビューの削除を取りやめます。 これがデフォルトです。

<title>Examples</title>

This command will remove the materialized view called <literal>order_summary</literal>: 以下のコマンドはorder_summaryという名前のマテリアライズドビューを削除します。

DROP MATERIALIZED VIEW order_summary;

互換性

<title>Compatibility</title>

<command>DROP MATERIALIZED VIEW</command> is a <productname>PostgreSQL</productname> extension. DROP MATERIALIZED VIEWPostgreSQLの拡張です。

関連項目

<title>See Also</title> CREATE MATERIALIZED VIEW, ALTER MATERIALIZED VIEW, REFRESH MATERIALIZED VIEW