SQL Server allows you to use the following network
libraries when establishing a connection. They are:
- dbnmpntw - Win32 Named Pipes
- dbmssocn - Win32 Winsock TCP/IP
- dbmsspxn - Win32 SPX/IPX
- dbmsvinn - Win32 Banyan Vines
- dbmsrpcn - Win32 Multi-Protocol (Windows RPC)
When connecting to SQL Server through ADO the NETWORK parameter
in the connection string can be used to specify which of these libraries to use
when connecting to the database. The NETWORK parameter is the name of the
Net-Library module to use, without the .dll suffix (for example, Dbmssocn, not
Dbmssocn.dll). Here are some examples of connection strings that specify this
parameter:
Note Make sure that User ID has the appropriate permissions to perform
this operation on the database.
- The following connection string:
"Provider=SQLOLEDB.1;Persist Security Info=False;User ID=<User
ID>;Initial Catalog=pubs;Data Source=<YourDataSourceName>;Network
Library=dbnmpntw"
tries to connect to SQL Server through the
SQLOLEDB provider using the Named Pipes network library. - The following connection string:
"Provider=MSDASQL.1;Persist Security Info=False;User ID=<User
ID>;Extended Properties="DSN=<yourdatasourcename>;UID=<User
ID>;DATABASE=pubs;Network Library=dbmssocn";Initial Catalog=pubs"
connects to SQL Server through the MSDASQL provider using the TCP/IP network
library.