Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save csharpforevermore/383c91e37d5ad030c9dae7ae1834d878 to your computer and use it in GitHub Desktop.
Save csharpforevermore/383c91e37d5ad030c9dae7ae1834d878 to your computer and use it in GitHub Desktop.
How to test your connection string using Powershell
$conn = New-Object System.Data.SqlClient.SqlConnection
$conn.ConnectionString = "Server=(local)\SQLEXPRESS;Database=SampleDatabase;Integrated Security=True;"
$conn.Open()
$conn.Close()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment