- Enterprise Edition
- Couchbase Server 7.0
DROP FUNCTIONstatement enables you to delete a user-defined function.
drop-function ::= DROP FUNCTION name
The name of the function. This is usually an unqualified identifier, such as
`func-1`. In this case, the path to the function is determined by the current query context.
To delete a global function in a particular namespace, the function name must be a qualified identifier with a namespace, such as
default:func1. Similarly, to delete a scope function in a particular scope, the function name must be a qualified identifier with the full path to a scope, such as
default:`travel-sample`.inventory.func1. Refer to Global Functions and Scope Functions for more information.
|The name of a user-defined function is case-sensitive, unlike that of a built-in function. You must delete the user-defined function using the same case that was used when it was created.|
This statement deletes an inline function called
DROP FUNCTION celsius;
You can run the following query to check that the function is no longer available.
SELECT * FROM system:functions;
This statement deletes an external function called
add in a library called
add function and
math library are still available.
$ curl -v -X GET \ http://localhost:8093/functions/v1/libraries \ -H 'content-type: application/json' \ -u Administrator:password