# SHOW CREATE VIEW
`SHOW CREATE VIEW` returns the `SELECT` statement used to create the view.

> For the complete documentation index, see [llms.txt](https://preview.materialize.com/materialize/40269/llms.txt).


`SHOW CREATE VIEW` returns the [`SELECT`](https://preview.materialize.com/materialize/40269/markdown-docs/sql/select/index.md) statement used to create the view.

## Syntax

```sql
SHOW [REDACTED] CREATE VIEW <view_name>;
```


| Syntax element | Description |
| --- | --- |
| <strong>REDACTED</strong> | If specified, literals will be redacted. |


For available view names, see [`SHOW VIEWS`](https://preview.materialize.com/materialize/40269/markdown-docs/sql/show-views/index.md).

## Examples

```mzsql
SHOW CREATE VIEW my_view;
```
```nofmt
            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:

- `USAGE` privileges on the schema containing the view.

## Related pages

- [`SHOW VIEWS`](https://preview.materialize.com/materialize/40269/markdown-docs/sql/show-views/index.md)
- [`CREATE VIEW`](https://preview.materialize.com/materialize/40269/markdown-docs/sql/create-view/index.md)
