Linux -Blue forest free software | Return to home page | Site Map | Search WWW | Contact Us |
Your current position : Homepage > Free Software > Technological exchanges >Application Programming


    

Blue Forest http://www.lslnet.com at 10:18 on June 6, 2006


How to judge Database Connection?

Members prawn, I used to visit the BCP API database, created the environment :
[/code]
SQLHENV henv;
SQLHDBC hdbc;

SQLAllocHandle (SQL_HANDLE_ENV, SQL_NULL_HANDLE, &henv);
SQLSetEnvAttr (henv, SQL_ATTR_ODBC_VERSION (void*) SQL_OV_ODBC3, 0)
SQLAllocHandle (SQL_HANDLE_DBC, henv, &hdbc);
SQLSetConnectAttr (hdbc, SQL_COPT_SS_BCP (SQLPOINTER) SQL_BCP_ON, SQL_IS_INTEGER);
SQLDriverConnect (. . . . .
[code]

Such a link has been established in the environment, how can we achieve it can be used to periodically check database connection? Thank you [/code]



 Privacy Policy  Copyright © 1999-2000 LSLNET.COM. All rights reserved. Blue Forest website owners. E-mail : Webmaster@lslnet.com