CouchDB - SPLessons

CouchDB Delete Database

Home > Lesson > Chapter 7
SPLessons 5 Steps, 3 Clicks
5 Steps - 3 Clicks

CouchDB Delete Database

CouchDB Delete Database

shape Description

Database is the peripheral informational structures in CouchDB in which all the records are saved and the essence of the database are saved in terms of documents rather then tabular forms and these database can be deleted based on Futon and with the utility of cURL.

Deleting a database using Futon

shape Description

The following steps describes the process of deleting a database using futon.

shape Step - 1

For deleting a database open http://127.0.0.1:5984/_utils/ from the web browser.

shape Step - 2

Click on splessons.

shape Step - 3

Click on Delete Database.

shape Step - 4

Click on Delete button.

shape Step - 5

Splesson database as been successfully deleted.

Deleting a database using cURL Utility

shape Description

Deleting a database can be done in CouchDB by passing a HTTP solicitation to the server utilizing Delete techniques over the utility of cURL.

shape Syntax

The syntax for deleting a database using cURL utility is as follows.
$ curl -X DELETE http://127.0.0.1:5984/database_name; X => HTTP request. Delete => The process of deleting a database by passing a request to server.

shape Examples

By viewing the below example,the concept of deleting a database can  be easily understand. [c] $ curl -X DELETE http://127.0.0.1:5984/Splessons { "ok" : true } $ curl -X GET http://127.0.0.1:5984/_all_dbs [ "_replicator " , " _users " ] [/c] Here in the above example a database by name Splessons has been successfully deleted.

Summary

shape Key Points

  • Deleting a database - Deleting a database from couchDB.
  • Deleting a database using futon - The process of deleting a database .
  • Deleting a database using cURL utility - Deleting a database by passing a HTTP solicitation to the server using Delete techniques.