Help Center > > Developer Guide> SQL Reference> SQL Syntax> DROP TYPE

DROP TYPE

Updated at:May 15, 2019 GMT+08:00

Function

DROP TYPE deletes a user-defined data type. Only the type owner has permission to run this statement.

Syntax

DROP TYPE [ IF EXISTS ] name [, ...] [ CASCADE | RESTRICT ]

Parameter Description

  • IF EXISTS

    Sends a notice instead of an error if the specified type does not exist.

  • name

    Specifies the name of the type to be deleted (schema-qualified).

  • CASCADE

    Deletes objects (such as columns, functions, and operators) that depend on the type.

    RESTRICT

    Refuses to delete the type if any objects depend on it. This is the default.

Examples

For details about CREATE TYPE, see Examples.

Helpful Links

ALTER TYPE, CREATE TYPE

Did you find this page helpful?

Submit successfully!

Thank you for your feedback. Your feedback helps make our documentation better.

Failed to submit the feedback. Please try again later.

Which of the following issues have you encountered?







Please complete at least one feedback item.

Content most length 200 character

Content is empty.

OK Cancel