DISCONNECT
SQL statement
Description
Executes a COMMIT for the specified transaction object and then
disconnects from the specified database.
Syntax
1 |
DISCONNECT {USING TransactionObject}; |
Parameter |
Description |
---|---|
TransactionObject |
The name of the transaction object that identifies |
Usage
Error handling
It is good practice to test the success/failure code after
executing a DISCONNECT statement.
Examples
Example 1
This statement disconnects from the database specified in the
default transaction object:
1 |
DISCONNECT ; |
Example 2
This statement disconnects from the database specified in the
transaction object named Emp_tran:
1 |
DISCONNECT USING Emp_tran ; |