Porovnávané verzie

Kľúč

  • Tento riadok sa pridal
  • Riadok je odstránený.
  • Formátovanie sa zmenilo.

DB_CONNECT action


Function
The action establishes a connection to a table in a database.


Declaration


Blok kódu
languageesl
themeConfluence
 DB_CONNECT dbObjIdent, accessIdent_Int, handleIdent_Int, retCodeIdent_Int [TRANS transHandle_Int]


Parameters


dbObjIdent

in

Reference to an object of the Database table type.
accessIdent_IntinValue identifier - required access to the database (_DB_READ, _DB_MODIFY).
handleIdent_IntoutIdentifier for the unique handle of the table connection.
retCodeIdent_IntoutReturn code identifier.
transHandle_Int

in

Identifier for the unique handle of the database connection.


Return code
The value of the parameter transHandle_Int. See the table of error codes. It is possible to get extended error information.
Description
Identifier for the number (handle) of the table connection is used for the next work with the actions DB_*. Return code describes the action success (__ERR_NO_ERROR).

For every opening a table by the script, a unique number is assigned (identifier, handle). Having finished work with the table, it is necessary to close this number using  the action DB_DISCONNECT. While all tables are not closed by calling the action DB_DISCONNECT after the script execution (opened by the script during its action), they are to be internally automatically closed. Handle may be transferred between ESL scripts in one process.

The value transHandle_Int must be gained by calling the action DB_TRANS_OPEN. If the identifier transHandle_Int is not used, the table connection will be executed by means of Automatic connection.