An understanding of how SQL Anywhere establishes connections can help you resolve connectivity problems. For information about network-specific issues, including connections across firewalls, see Client/server communications.
To establish a connection, SQL Anywhere:
Locates the interface library
Assembles a list of connection parameters
Locates a server
Locates the database
Starts a personal server when the database server is not located
The SQL Anywhere connection procedure is the same for:
Any ODBC application using the SQLDriverConnect function, which is the common connection method for ODBC applications. Many application development systems, such as Sybase PowerBuilder, belong to this class of application. The SQLConnect function is also available to ODBC applications.
Any client application using embedded SQL and using the recommended function for connecting to a database (db_string_connect). In addition, the SQL CONNECT statement is available for embedded SQL applications and in Interactive SQL. It has two forms: CONNECT AS ... and CONNECT USING. All the database administration tools, including Interactive SQL, use db_string_connect.
Any ADO application using the ADODB Connection object. The Provider property is used to locate the OLE DB driver. The Connection String property may use DataSource as an alternative to DataSourceName and User ID as an alternative to UserID.
Any application using the iAnywhere JDBC driver to pass the URL jdbc:ianywhere: followed by a standard connection string as a parameter to the Driver Manager.GetConnection method. The connection string must include DataSource= and name a SQL Anywhere data source or include Driver=SQL Anywhere 11 (this parameter is specified as Driver=libdbodbc11.so on Linux and Unix).
Locating the interface library
Assembling a list of connection parameters
Locating a database server
Locating a database server using the Broadcast Repeater utility
Locating the database
Server name caching for faster connections
Interactive SQL connections
Testing that a server can be found
Testing embedded SQL connection performance
|Envoyer votre avis sur cette page par email.||Copyright © 2009, iAnywhere Solutions, Inc. - SQL Anywhere 11.0.1|