Salesforce

DbDiscnt (Magic xpa 2.x)

« Go Back

Information

 
Created ByKnowledge Migration User
Approval Process StatusPublished
Objective
Description

DbDiscnt (Magic xpa 2.x)

Receives a database as a parameter and disconnects the current connection of that database. The DbDiscnt function is relevant only for SQL databases.

Disconnecting is only allowed if there is no cursor open on the database that you are trying to disconnect from. If there is a cursor open and the user issues a DbDiscnt command, an error message will be displayed.

Allows the developer to disconnect the current database connection in order to:

  • Disconnect a user from a database connection no longer needed in the application

  • Disconnect a user from a database connection in order to connect another user to the same database connection

Syntax:

DbDiscnt(string)

Parameters:

string – An Alpha string or Alpha string expression containing the database name.

Returns:

Boolean (True, False).
Returns True when the Disconnect operation has succeeded, and False when the Disconnect operation has not succeeded or when there is no connection to disconnect.

Example:

DbDiscnt('MSSQL'), where MSSQL is the database name defined in the Database repository.

Note:

To disconnect from a local database, see ClientDbDiscnt.

Reference
Attachment 
Attachment