mirror of
https://github.com/ckaczor/sqltoolsservice.git
synced 2026-01-25 17:24:17 -05:00
Addressing feedback
This commit is contained in:
@@ -506,7 +506,10 @@ namespace Microsoft.SqlTools.ServiceLayer.Connection
|
||||
{
|
||||
try
|
||||
{
|
||||
info.SqlConnection.ChangeDatabase(newDatabaseName);
|
||||
if (info.SqlConnection.State == ConnectionState.Open)
|
||||
{
|
||||
info.SqlConnection.ChangeDatabase(newDatabaseName);
|
||||
}
|
||||
info.ConnectionDetails.DatabaseName = newDatabaseName;
|
||||
|
||||
// Fire a connection changed event
|
||||
|
||||
Reference in New Issue
Block a user