Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 17 » SQL Anywhere Server - Database Administration » Database connections

Troubleshooting: connections

An understanding of how connections are established can help you resolve connectivity problems.

Ensure you are familiar with communication protocols and network-specific issues, including connections across firewalls.

To establish a connection, the software:

  1. Locates the interface library.

  2. Assembles a list of connection parameters.

  3. Locates a database server. If the database server is not found, then a personal server is started.

  4. Locates the database.

The 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 SAP 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 CONNECT SQL statement is available for Embedded SQL applications and in Interactive SQL. It has two forms: CONNECT AS and CONNECT USING. All the database utilities, including dbisqlc, use db_string_connect.

  • Any .NET application using ADO.NET. The application creates a new SAConnection object and passes the connection string to the constructor or sets the ConnectionString property. Then the application calls the Open method on the SAConnection object to connect.

  • Any ADO application using the ADODB Connection object. The Provider property is used to locate the OLE DB driver. The ConnectionString property may use DataSource as an alternative to DataSourceName and User ID as an alternative to UserID.

  • Any application using the SQL Anywhere JDBC driver to pass the URL jdbc:sqlanywhere: followed by a standard connection string as a parameter to the Driver Manager.GetConnection method.