Wednesday, October 14, 2009

Heather Harmon Out Of Retirement

Get the version of SQL Server Powershell

$ sqlcnx = New-Object System.Data.SqlClient.SqlConnection
$ sqlcnx.ConnectionString = "Server = SERVERNAME ; Database = master; Integrated Security = True" $
sqlcnx.Open ()
$sqlcnx.ServerVersion

0 comments:

Post a Comment