tags:

views:

289

answers:

1

I need a free and quick to download program that can test a connection string.

Thanks

+5  A: 

You can make one yourself in 20sec. For example in C#
- Create a new WinForms application
- Create a new SqlConnection(connectionString)
- Exception => Bad connection string
- All ok => Good connection string

SqlConnection conn = null;

try {
  conn = new SqlConnection("connection string here");
  conn.Open();
  // Good connection string
} catch (SqlException sqlE) {
  // Bad connection string
} finally {
  if (conn != null) conn.Dispose();
}
Zyphrax
Shouldn't you use conn.Close opposed to conn.Dispose ?
Dan Revell
That's not necessary, almost all (if not all) objects that implement the iDisposable pattern automatically Release/Close/Quit/Shutdown any resources held by that object.You might be familiar with the using-directive, it basically generates exactly the same code I wrote above.
Zyphrax