SQL -Structured Query Language - SQL Database - Drop Database Tutorial
To delete or remove an existing SQL database, we can use a ' DROP DATABASE ' statement.
Syntax-
The basic syntax of the DROP DATABASE statement is given below –
DROP DATABASE DatabaseName;
For example-
If we want to delete or remove database employees which we have already created.
Then use the following syntax-
DROP DATABASE employees;
You can try all examples in MySQL workbench.
Click here to install MySQL workbench.
- Open a query editor mark on the left side.
- Write a basic query such as ' drop database employees '
- Click on execute (power symbol)
It will delete or remove database employees.
If the output shows a green mark then it is executed successfully.
If it still not showing click on refresh, marked in an image.