Which Connection String to use
I have multiple programs that access a single connection string in a ini file. Some of the programs are .net and some are not. I am using the following connection string.
ConnectionString=Provider=SQLNCLI10;Server=myServerAddress;Database=myDataBase;Uid=myUsername; Pwd=myPassword;
Is this the best for the connecting to 2005, 2008 and 2008 R2 Sql Server?
Secondly should I include a network protocol to improve performance?
2 answers
ConnectionString=
Provider=SQLNCLI10;
Server=myServerAddress;
Database=myDataBase;
Uid=myUsername;
Pwd=myPassword;
For SQL Server 2012 you will need to use SQLNCLI11 for the provider.