tran_dumpable_status

Description

Returns a true/false indication of whether dump transaction is allowed.

Syntax

tran_dumpable_status("database_name") 

Parameters

database_name

is the name of the target database.

Examples

Example 1

Checks to see if the pubs2 database can be dumped:

1> select tran_dumpable_status("pubs2")
2> go
 ----------- 
         106

(1 row affected)

In this example, you cannot dump pubs2. The return code of 106 is a sum of all the conditions met (2, 8, 32, 64). See the Usage section for a description of the return codes.

Usage

tran_dumpable_status allows you to determine if dump transaction is allowed on a database without having to run the command. tran_dumpable_status performs all of the checks that Adaptive Server performs when dump transaction is issued.

If tran_dumpable_status returns 0, you can perform the dump transaction command on the database. If it returns any other value, it cannot. The non-0 values are:

Standards

ANSI SQL – Compliance level: Transact-SQL extension.

Permissions

Any user can execute this function.

See also

Command dump transaction