300x250 AD TOP

helooo
Tagged under:

Creating database



Syntax:

CREATE DATABASE DatabaseName;
Always database name should be unique within the RDBMS.
Example:
If you want to create new database  testDB, then CREATE DATABASE statement would be as follows:
SQL> CREATE DATABASE testDB;

o/p:--

Command(s) completed successfully.

Make sure you have admin privilege before creating any database. Once a database is created, you can check it in the list of databases as follows:


SQL> SHOW DATABASES;
+--------------------+
| Database           |
+--------------------+           |
| venkatesh_db       |
| mysql              |
| orig               |
| test               |
| testDB             |
+--------------------+
5 rows in set (0.00 sec)