Erasing a database deletes all tables and data from disk, including the transaction log that records alterations to the database. All database files are read-only to prevent accidental modification or deletion of database files. By default, you need DBA authority to erase a database. You can change the required permissions by using the database server -gu option. See -gu server option.
In Sybase Central, you can erase a database using the Erase Database Wizard.
In Interactive SQL, you can erase a database using the DROP DATABASE statement.
You can also erase a database from a command line with the dberase utility. However, the dberase utility does not erase dbspaces. If you want to erase a dbspace, you can do so with the DROP DATABASE statement or using the Erase Database Wizard in Sybase Central.
The database to be erased must not be running when the dberase utility, the Erase Database Wizard, or DROP DATABASE statement is used. You must be connected to a database to drop another database.
For information about connecting to the utility database, see Connecting to the utility database.
Windows Mobile databases must be erased manually. See Erase a Windows Mobile database.
Choose Tools » SQL Anywhere 11 » Erase Database.
Follow the instructions in the wizard.
You can also access the Erase Database Wizard from within Sybase Central by using any of the following methods:
Selecting a database server, and choosing File » Erase Database.
Right-clicking a server, and choosing Erase Database.
Connect to a database other than the one you want to erase. For example, connect to the utility database.
Execute a DROP DATABASE statement.
For example, the following DROP DATABASE statement erases a database named temp.
DROP DATABASE 'c:\\temp\\temp.db';
Run the dberase utility.
For example, the following command removes the temp database.
|Envoyer votre avis sur cette page par email.||Copyright © 2009, iAnywhere Solutions, Inc. - SQL Anywhere 11.0.1|