Table of contents
TOC
Collapse the table of content
Expand the table of content

DROP TYPE (U-SQL)

Michael Rys|Last Updated: 5/15/2018
|
4 Contributors

U-SQL named types can be deleted with the DROP TYPE statement.

Warning

This operation cannot be undone!

Syntax
Drop_Type_Statement :=                                                                                   
    'DROP' 'TYPE' ['IF' 'EXISTS'] Type_Identifier.
Type_Identifier := DB_Object_Identifier.

Semantics of Syntax Elements

  • Type_Identifier
    Specifies the type to be dropped in the current static database context. If the name is a two-part name, the type will be dropped in the specified database. If the name is a simple identifier, then the procedure will be dropped in the current database context.

    If a type of the given name does not exist, or the user has no permissions to drop the type, an error is raised.

  • IF EXISTS
    If the optional IF EXISTS is specified, then the statement drops the type if it exists, or succeeds without changes if the type does not exist or the user has no permission to at least enumerate all existing types.

Example

  • The example can be executed in Visual Studio with the Azure Data Lake Tools plug-in.
  • The script can be executed locally. An Azure subscription and Azure Data Lake Analytics account is not needed when executed locally. sql DROP TYPE TestReferenceDB.dbo.PhoneType;

See Also

© 2018 Microsoft