Skip to main content

DROP SCHEMA

Remove a schema.

Syntax

Parameters

ParameterDescription
IF EXISTSDo not raise an error if the schema does not exist
schema_nameName of the schema to remove
CASCADEDrop the schema and all objects it contains
RESTRICTRefuse to drop if the schema contains any objects (default)

Examples

DROP SCHEMA IF EXISTS analytics CASCADE;

See also