Daylight v4.9
Release Date: 1 February 2008


dt_thor_destroy - permanently removes a database

Generic Prototype

dt_thor_destroy(dt_Handle, dt_String, dt_String) => dt_Boolean

C Prototype

#include "dt_thor.h"

dt_Boolean dt_thor_destroy(dt_Handle server, dt_Integer dlen, dt_String dbname, dt_Integer plen, dt_String password)

FORTRAN Prototype

include ''

integer*4 dt_f_thor_destroy(server, dbname, password)

integer*4 server
character*() dbname
character*() password


Removes a database from the disk. Destroys it completely and without possibility of recovery.

The database name must be complete including a full directory path from the root of the host machine's file system, e.g. /thordb/mydb or $DY_THORDB/mydb.

A database can only be destroyed if it is closed -- i.e. nobody is using it and it is not marked "hold" (see dt_hold(3)). If it is open, this function fails.

The parameter "password" must contain the "executive" password for the database.

Return Value

Returns TRUE if the database is successfully destroyed, or FALSE if an error is detected.

Related Topics

dt_hold(3) dt_release(3) dt_thor_createdb(3)