You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if ($isNewConnection-and$isFailoverPartnerError-and-not$connectionSucceeded-and$inputObjectType-eq'String') {
1139
+
Write-Message-Level Verbose -Message "Connection failed because the server is configured for database mirroring (Failover Partner requires Initial Catalog). Retrying with Initial Catalog=master."
# Add Initial Catalog=master to satisfy the Failover Partner connection string requirement
1144
+
if ($server.ConnectionContext.SqlConnectionObject.ConnectionString-notmatch"Initial Catalog"-and$server.ConnectionContext.SqlConnectionObject.ConnectionString-notmatch"Database=") {
1145
+
if ($server.ConnectionContext.SqlConnectionObject.ConnectionString-match";$") {
0 commit comments