Tests the network response time of the underlying connectivity between a client and a database server. This API can be used by an application when a host database server is accessed via DB2 Connect either directly or through a gateway.
Berechtigung
None
Erforderliche Verbindung
Database
API-Include-Datei
db2ApiDf.h
C-API-Syntax
/* File: db2ApiDf.h */ /* API: Ping Database */ /* ... */ SQL_API_RC SQL_API_FN db2DatabasePing ( db2Uint32 versionNumber, void *pParmStruct, struct sqlca * pSqlca); /* ... */ typedef SQL_STRUCTURE db2DatabasePingStruct { char iDbAlias[SQL_ALIAS_SZ + 1]; db2Uint16 iNumIterations; db2Uint32 *poElapsedTime; }
Generische API-Syntax
/* File: db2ApiDf.h */ /* API: Ping Database */ /* ... */ SQL_API_RC SQL_API_FN db2gDatabasePing ( db2Uint32 versionNumber, void *pParmStruct, struct sqlca * pSqlca); /* ... */ typedef SQL_STRUCTURE db2gDatabasePingStruct { db2Uint16 iDbAliasLength; char iDbAlias[SQL_ALIAS_SZ]; db2Uint16 iNumIterations; db2Uint32 *poElapsedTime; }
API-Parameter
Hinweise zur Verwendung
A database connection must exist before invoking this API, otherwise an error will result.
This function can also be invoked using the PING command. For a description of this command, see the Command Reference.