ArangoDB v3.4 reached End of Life (EOL) and is no longer supported.
This documentation is outdated. Please see the most recent version here: Latest Docs
Deleting Views
Views, just as collections, can be removed from a database. View removal is achieved via an API common to all view types, as follows:
Drops a view
drops a view
DELETE /_api/view/{view-name}
Path Parameters
- view-name (string, required): The name of the view to drop.
Drops the view identified by view-name.
If the view was successfully dropped, an object is returned with the following attributes:
- error: false
- id: The identifier of the dropped view
Responses
HTTP 400: If the view-name is missing, then a HTTP 400 is returned.
HTTP 404: If the view-name is unknown, then a HTTP 404 is returned.
Examples
Using an identifier:
shell> curl -X DELETE --header 'accept: application/json' --dump - http://localhost:8529/_api/view/71340
HTTP/1.1 OK
content-type: application/json; charset=utf-8
x-content-type-options: nosniff
{
"error" : false,
"code" : 200,
"result" : true
}
Hide response body
shell> curl -X DELETE --header 'accept: application/json' --dump - http://localhost:8529/_api/view/71340
HTTP/1.1 OK
content-type: application/json; charset=utf-8
x-content-type-options: nosniff
Using a name:
shell> curl -X DELETE --header 'accept: application/json' --dump - http://localhost:8529/_api/view/testView
HTTP/1.1 OK
content-type: application/json; charset=utf-8
x-content-type-options: nosniff
{
"error" : false,
"code" : 200,
"result" : true
}
Hide response body
shell> curl -X DELETE --header 'accept: application/json' --dump - http://localhost:8529/_api/view/testView
HTTP/1.1 OK
content-type: application/json; charset=utf-8
x-content-type-options: nosniff