disk unmirror  drop default

Chapter 1: Commands

drop database

Description

Removes one or more databases from Adaptive Server.

Syntax

drop database database_name [, database_name] ...

Parameters

database_name

is the name of a database to remove. Use sp_helpdb to get a list of databases.

Examples

Example 1

Removes the publishing database and all its contents:

drop database publishing

Usage


Restrictions

Standards

ANSI SQL – Compliance level: Transact-SQL extension.

Permissions

Only the Database Owner can execute drop database, except for the sybsecurity database, which can be dropped only by the System Security Officer.

Auditing

Values in event and extrainfo columns of sysaudits are:

Event

Audit option

Command or access audited

Information in extrainfo

26

drop

drop database

  • Roles – Current active roles

  • Keywords or options – NULL

  • Previous value – NULL

  • Current value – NULL

  • Other information – NULL

  • Proxy information – Original login name, if set proxy in effect

See also

Commands alter database, create database, dbcc, use

Procedures sp_changedbowner, sp_helpdb, sp_renamedb, sp_spaceused





Copyright © 2005. Sybase Inc. All rights reserved. drop default

View this book as PDF