Amazon Athena
User Guide

Supported Actions for Views in Athena

Athena supports the following actions for views. You can run these commands in the Query Editor.

Statement Description
CREATE VIEW

Creates a new view from a specified SELECT query. For more information, see Creating Views.

The optional OR REPLACE clause lets you update the existing view by replacing it.

DESCRIBE VIEW

Shows the list of columns for the named view. This allows you to examine the attributes of a complex view.

DROP VIEW

Deletes an existing view. The optional IF EXISTS clause suppresses the error if the view does not exist. For more information, see Deleting Views.

SHOW CREATE VIEW

Shows the SQL statement that creates the specified view.

SHOW VIEWS

Lists the views in the specified database, or in the current database if you omit the database name. Use the optional LIKE clause with a regular expression to restrict the list of view names. You can also see the list of views in the left pane in the console.

SHOW COLUMNS

Lists the columns in the schema for a view.