Connecting to a SQL Server Data Source

When an application connects to SQL Server using SQLDriverConnect, the application may generate a prompt for data source information. This prompt can be in the form of a Data Source query or a dialog box. For a Data Source query, enter the name of the data source. For a dialog box, complete the dialog box as follows:

  1. Enter or select the data source name.
  2. In the Login ID entry field, type your SQL Server login ID.
  3. In the Password entry field, type your SQL Server password.
  4. Choose OK.

For information about the SQL Server login security mode and secure connections, see the Microsoft SQL Server Administrator's Companion.

To enter optional connection information, such as the database to access and the language for SQL Server to use, choose the Options button.

  1. From the Database list box, select the database you want to access. Setting the default database and the language for the login ID in SQL Server is more efficient than specifying them as DSN options.

    When you open the list box, the user's default database is selected.

  2. From the Language box, select the language you want SQL Server to use. Setting the default database and the language for the login ID in SQL Server is more efficient than specifying them as DSN options.

    When you open the list box, the user's default language is selected.

  3. If the application name that is displayed is incorrect, enter the correct application name.

    The application name is the name of the application that is calling the SQL Server driver.

  4. If the workstation ID that is displayed is incorrect, enter the correct workstation ID.

    Typically, this is the network name of the computer on which the application resides.

  5. Choose OK.