Removes a user-defined function from the database. Once dropped, the function can no longer be used in queries.Documentation Index
Fetch the complete documentation index at: https://docs.firebolt.io/llms.txt
Use this file to discover all available pages before exploring further.
Syntax
Parameters
| Parameter | Description |
|---|---|
IF EXISTS | Prevents an error if the function does not exist. If specified and the function does not exist, the statement completes successfully without error. |
<schema_name> | The schema containing the function. Currently, only the public schema is supported for user-defined functions. |
<function_name> | The name of the function to drop. Function names are case-insensitive. |
Examples
Drop a function
Drop a function if it exists
UseIF EXISTS to avoid errors when the function might not exist:
Limitations
- Built-in functions: You cannot drop built-in Firebolt functions. Attempting to do so results in an error.
- CASCADE not supported: The
CASCADEoption is not supported. If other database objects depend on the function, you must drop them separately. - Schema restriction: Only functions in the
publicschema can be dropped, as user-defined functions in custom schemas are not currently supported.
Related
- CREATE FUNCTION - Create a user-defined function