This example illustrates how to connect to a SQL Server database through ADO. These instructions are applicable when you use a native SQL Server provider such as SQL Server Native Client 11.0 and also when you use the Microsoft OLE DB Provider for SQL Server provider.
To connect to SQL Server:
2.Select Microsoft SQL Server (ADO), and then click Next. The list of available ADO drivers is displayed. In this example, the SQL Server Native Client 11.0 is used as provider. You can also select the Microsoft OLE DB Provider for SQL Server provider.
3.Click Next. The Data Link Properties dialog box appears.
4.Select or enter the name of the database server, for example, SQLSERV01. If you are connecting to a named SQL Server instance, the server name looks like SQLSERV01\SOMEINSTANCE. To view the list of all servers on the network, expand the drop-down list.
5.If the database server was configured to allow connections from users authenticated on the Windows domain, select Use Windows NT integrated security. Otherwise, select Use a specific user name and password, clear the Blank password check box, and enter the credentials in the relevant boxes.
6.Select the database to which you are connecting (in this example, Nanonull).
7.To test the connection at this time, click Test Connection. This is an optional, recommended step.
Even if the connection test is successful at this time, you must still persist the security info, see the next step.
8.Click the All tab, and change the Persist Security Info property to True.