SHOW CREATE VIEW
SHOW CREATE VIEW returns the SELECT statement used to create the view.
Syntax
SHOW [REDACTED] CREATE VIEW <view_name>
| Option | Description |
|---|---|
| REDACTED | If specified, literals will be redacted. |
For available view names, see SHOW VIEWS.
Examples
SHOW CREATE VIEW my_view;
name | create_sql
----------------------------+--------------------------------------------------------------------------------------------------
materialize.public.my_view | CREATE VIEW "materialize"."public"."my_view" AS SELECT * FROM "materialize"."public"."my_source"
Privileges
The privileges required to execute this statement are:
USAGEprivileges on the schema containing the view.