SQL CREATE DATABASE is a command to create a new database in RDBMS such as MySQL, SQL Server, Oracle, and others. The statement creates an empty database with the specified name given by the user.



The basic syntax for creating a new database using SQL is:

Syntax:

CREATE DATABASE database_name;

For example, to create a new database named "mydb", you would use the following SQL statement:

Example:

CREATE DATABASE mydb;

When this statement is executed, a new database is created with the specified name. The new database will be empty and contain no tables. You can then use other SQL statements to create tables, insert data, and perform other operations on the new database.



Found This Useful? Share This Page!