disconnect database

Close a database connection.
NameDescriptionTypeModifier
name

Name of the database connection (previously established via the connect database action).

StringNone
None
The following settings are applicable to this action: remove double quotes from cells.
The following example illustrates the process of a test connecting to, using, and then disconnecting from a database. Use the action disconnect database once you no longer require access to the database.
                                
variabledriverhost
create connection stringNorthwind_conn_strgSQL Serverlgdn15031-w7d01
 
portdatabase nameusername
>>>Northwind
 
passwordothers
>>>Trusted_Connection=Yes
 
connection stringname
connect database#Northwind_conn_strgNorthwind_conn
 
name
use databaseNorthwind_conn
 
commandresult
execute sqlselect ContactName from Customers where CustomerID='ABOUT'contactname_ds
 
namefilter
use data setcontactname_ds
 
valueexpected
check value#ContactNameThomas Hardy
 
repeat for data set
 
name
disconnect databaseNorthwind_conn
  • Note that it is permissible for your test to be connected to more than one database concurrently. In order to switch to using a different database, it is not necessary to disconnect from the current one.
  • This action supports the <ignore> modifier. If the string <ignore> is present as the value of the argument, or the argument contains an expression that evaluates to <ignore>, the action is skipped during execution.

Copyright © 2025 LogiGear Corporation. All rights reserved. LogiGear is a registered trademark, and Action Based Testing and TestArchitect are trademarks of LogiGear Corporation. All other trademarks contained herein are the property of their respective owners.

LogiGear Corporation

1730 S. Amphlett Blvd. Suite 200, San Mateo, CA 94402

Tel: +1 (650) 572-1400