The following table lists the parameters you must define in a file DSN for each type of database. In each case, use the driver name for your database that is provided in the table.
Database Type |
Parameters |
DB2 |
File DSNs are not supported for DB2 databases. You must use system DSNs. |
dBase 5 |
Driver={Dbase} DBQ=[pathname] defaultDir=[default_directory] where [pathname] is the absolute path name of the directory containing the database file and [default_directory] is the default directory for the database. |
Informix 7, 9 |
Driver={Informix} Server=[server_name] Database=[database_name] UID=[username] PWD=[password] where [server_name] is the name of the database server, [database_name] is the name of the database, and [username] and [password] are the username and password required for accessing the database. |
Microsoft Access |
DSN-less connection strings and file DSNs are not supported for Microsoft Access databases. You must use system DSNs. |
Microsoft SQL Server 6.5 |
DSN-less connection strings and file DSNs are not supported for Microsoft SQL Server 6.5 databases. You must use system DSNs. |
Microsoft SQL Server 7.0 |
Driver={SQL Server} Database=[database_name] UID=[username] PWD=[password] where [database_name] is the name of the database, and where [username] and [password] are the username and password required for accessing the database. Note that before you can reference a Microsoft SQL Server 7.0 database in a DSN-less connection string or a file DSN, your system administrator must take the steps described in "Editing the Microsoft SQL Server Template" in "Chapter 3: Managing Chili!Soft ASP." |
MySQL |
Driver={Mysql} Server=[server_name] Database=[database_name] UID=[username] PWD=[password] where [server_name] is the name of the database server, [database_name] is the name of the database, and [username] and [password] are the username and password required for accessing the database. |
Oracle 7 |
Driver={Oracle7} Server=[TNS_name] UID=[username] PWD=[password] where [TNS_name] is the TNS name as defined in the tnsnames.ora file, and [username] and [password] are the username and password required for accessing the database. |
Oracle 8, 8i |
Driver={Oracle8} Server=[TNS_name] UID=[username] PWD=[password] where [TNS_name] is the TNS name as defined in the tnsnames.ora file, and [username] and [password] are the username and password required for accessing the database. |
PostgreSQL |
Driver={Postgres} Server=[server_name] UID=[username] PWD=[password] where [server_name] is the name of the database server, and [username] and [password] are the username and password required for accessing the database. |
Sybase 11 |
Driver={Sybase} Server=[server_name] Database=[database_name] UID=[username] PWD=[password] where [server_name] is the name of the database server, [database_name] is the name of the database, and [username] and [password] are the username and password required for accessing the database. |
See also:
Using File DSNs in this chapter
Copyright 2001 Sun Microsystems, Inc. All rights reserved. Legal Notice.