The mi_dbdrop() function

The mi_dbdrop() function drops a database from the given connection.

Syntax

mi_integer mi_dbdrop(conn, db_info)
   MI_CONNECTION *conn;
   const MI_DATABASE_INFO *db_info;
conn
A pointer to a connection descriptor established by a previous call to mi_open(), mi_server_connect(), or mi_server_reconnect().
db_info
A pointer to a database-information descriptor that identifies the database to drop.
Valid in client LIBMI application? Valid in user-defined routine?
Yes No

Usage

The mi_dbdrop() function is equivalent to the SQL DROP DATABASE statement. A field in the database-information structure that dbinfo references contains the database name.

For additional information about the MI_DATABASE_INFO structure, see the description of the mi_get_database_info() function.

Return values

MI_OK
The function was successful; the database was dropped.
MI_ERROR
The function was not successful. An exception was raised, and the database was not created.