Join the MemSQL Community Today
Get expert advice, develop skills, and connect with others.

DROP DATABASE

Drop the specified database.

Syntax

DROP DATABASE [IF EXISTS] db_name [FORCE]

DROP SCHEMA [IF EXISTS] db_name [FORCE]

Remarks

  • db_name is the name of a MemSQL database.
  • This command must be run on the master aggregator node (see Node Requirements for MemSQL Commands).
  • By default, the DROP DATABASE command waits for the running queries to finish before dropping the database. To override this behavior and kill any running queries, use the FORCE option.

Example

memsql> DROP DATABASE IF EXISTS test;
memsql> DROP DATABASE IF EXISTS db FORCE;