Connection string

The following must be added to the connection string to identify the sql.ini or interfaces file. You can connect to a single Directory Services URL (DSURL) or to multiple DSURLs.


Connection string for a single DSURL

For a single DSURL for ADO.NET, ODBC, and the OLE DB drivers and providers, you must add the following properties to the connection string in the following format:

DSURL=file://[path]<filename>[?][servicename]

where:

Examples of the connection string for Windows and UNIX:

Windows

Example using a default path:

Example using explicit path:

Linux and Mac OS X

Example using a default path:

Example using explicit path:


Connection string for multiple URLs

DSURL can support multiple LDAP URLs and interfaces files. Sybase also supports a multiple URL with mixed LDAP URLs and file URLs. When multiple URLs are used, the driver processes the URLs one by one until it successfully opens an interfaces file or connects to an LDAP server.

Examples of multiple URLs

The following are examples of using multiple URLs in a connection string:

DSURL={file:///mils1/sybase/sql.ini;file:///test/interface}
DSURL={ldap://SYBLDAP:389/dc=sybase,dc=com??one?sybaseServername=MANGO;
ile:///test/interface?MANGO}

Format of the interfaces file for Microsoft Windows, UNIX, and SSL

For information on the format of the interfaces file, see the Adaptive Server Enterprise Configuration Guide for your platform.