Modifying the connection string

This section describes what you must add to the connection string to identify the sql.ini or interfaces file. On jConnect for JDBC, you may only connect to a single Directory Services URL (DSURL).

NotejConnect does not support multiple-URLs.


Connection string for a single DSURL for jConnect

For a single DSURL for jConnect, add the following properties to the connection string in the following format:

NoteYou must specify the path to the sql.ini file and the server name.

String url = "jdbc:sybase:jndi:file://D:/syb1252/ini/mysql.ini?myaseISO1”

where:

If the sql.ini path or server name is not specified in the URL, the driver returns an error.


Format for the interfaces file for SSL

The following is the format for the sql.ini file for SSL:

[SYBSRV2]
master=nlwnsck,mango1,4100,ssl
query=nlwnsck,mango1,4100,ssl
query=nlwnsck,mango1,5000,ssl

NotejConnect supports multiple query entries under the same server name in the sql.ini file. jConnect attempts to connect to values for host or port from the query entry in the sequence, as in the sql.ini file. If jConnect finds an SSL in a query entry, it will require the application to be coded to handle SSL connections by specifying an application specific socket factory, or the connection may fail.