A data source name (DSN) consists of a number of parameters that supply information about the database server to which you're connecting and the ODBC driver you are using. Depending on the type of data connection you are creating, you do not necessarily need to supply a value for every parameter.
The following table describes some common parameters and their values.
Note Individual ODBC drivers may have their own additional parameters which appear in the connection string. For information about specific ODBC driver parameters, see the documentation for that ODBC driver.
Parameter | Description |
DRIVER | The type of ODBC driver. |
DSN or FileDSN | The name of the data source. The DSN parameter denotes a machine data source. The FileDSN parameter denotes a file data source. However, if the DSN parameter is present in a Web application, the connection is a DSN connection. If this parameter is absent, then the connection is a DSN-less connection. |
SERVER | The name of the server or the default directory in which the database resides. |
UID | The user ID to use when connecting to the database server at design time. |
PWD | The password to use when connecting to the database server at design time. The PWD parameter does not appear in the DSN. |
APP | Optional. The name of the software application. |
WSID | Optional. The workstation ID of the computer you are working on. |
DATABASE | The name of the database you are connecting to. |
Note If you’re connecting to a Microsoft® SQL Server™ database, make sure that the DATABASE parameter is present in the DSN. Otherwise you’ll automatically connect to the master database on the server.