Επεξεργασία

Κοινή χρήση μέσω


Establishing a Connection

After allocating environment and connection handles and setting any connection attributes, the application is ready to connect to the data source or driver. There are three different functions the application can use to do this: SQLConnect (Core interface conformance level), SQLDriverConnect (Core), and SQLBrowseConnect (Level 1). Each of the three is designed to be used in a different scenario. Before connecting, the application can determine which of these functions is supported with the ConnectFunctions keyword returned by SQLDrivers.

Note

Some drivers limit the number of active connections they support. An application calls SQLGetInfo with the SQL_MAX_DRIVER_CONNECTIONS option to determine how many active connections a particular driver supports.

This section contains the following topics.