Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SAP SQL Anywhere, on-demand edition 1.0 SP 6 » Task syntax

StopDatabase task

Stops a running database.

Syntax 1 (SQL)
CALL DBCloud.StopDatabase ( database_list=database_list [, optional-parameters ] )
Syntax 2 (Cloud Command utility)
dbcloudcmd run StopDatabase database_list [ optional-parameters ]
Parameters
  • database_list

    A list of databases to stop. Accepts a search query that identifies databases. The search query can be a list of database names or IDs separated by semicolons (;), or a full search. (Required)

  • unconditionally

    Set to 1 to stop unconditionally. Set to 0 to stop only if there are no connections. The default is 1.

Required privileges

StartStopDatabase

Parameter remarks
  • unconditionally

    When database that is configured to autostop has had its ability to stop automatically disabled, for example it was started with a StartDatabase task, and the StopDatabase unconditionally=0 is run, the database has client connections and is configured to autostop, but it was started manually by a StartDatabase task, then running StopDatabase unconditionally=0 results in re-enabling the database to stop automatically after the last client connection disconnects.

Remarks

This task stops the specified database, including its database copies.

Running the DisableConnections task before stopping the database prevents new connections from being formed while the database is being stopped.

Example

Run the following task to stop the database mydatabase:

dbcloudcmd run StopDatabase database_list=mydatabase

Run the following task to stop all databases that are running in the cloud:

dbcloudcmd run StopDatabase "status:running"