Sets a databank offline or online, with the option of clearing
LOGDBrecords for it.
Setting a databank
OFFLINEmakes it unavailable for all users and closes the databank file. A typical use for this is when taking databank backups using the host file system.
If the databank is being used, an error will be raised and it will not be set offline. When a databank is set offline, all online shadows will be brought up to date.
When a databank is set
ONLINEagain, you must specify whether to clear the
LOGDBrecords for it (using the
RESET LOGoption), or whether to preserve these (using the
PRESERVE LOGoption). The
RESET LOGoption should be used after a successful backup has been taken.
It is essential to keep
LOGDBin a state consistent with the databank backups, see the Mimer SQL System Management Handbook, Backing-up and Restoring Data, for a discussion of the issues.
Clearing records from
LOGDBis handled automatically when
CREATE BACKUPis used to take databank backups.
The current ident must either be the creator of the databank or have
While a databank is
OFFLINE, none of the tables stored in it are accessible and the updating of all its shadows is suspended. It is possible to use
ALTER DATABANK RESTOREto change or recover a databank while it is
ALTER DATABANKwas used to change the location of the databank file while the databank was
SET DATABANKstatement will verify that the new file contains a valid copy of the databank when the databank is set
ONLINEagain (it cannot, however, check that the contents of the file is up-to-date).
It is possible to use
DROP DATABANKto drop an
While a databank is
OFFLINE, it is not possible to use
ALTER SHADOWon any of its shadows.
An error will be raised if an attempt is made to set a databank
OFFLINEthat is already
ONLINEwhen it is already
ExampleSET DATABANK usrdb OFFLINE;
For more information, see the Mimer SQL System Management Handbook, Backing-up and Restoring Data.
Mimer Information Technology AB
Phone: +46 18 780 92 00