大网数据广告活动
数据库与应用安全

Object Explorer intermittently crashes

· 52CE 我爱测

This article provides resolution for the problem where the Object Explorer intermittently hangs when you use SQL Server Management Studio 2012 or a later version.

This article helps you resolve the problem where the Object Explorer intermittently hangs when you use SQL Server Management Studio (SSMS) 2012 or a later version.

Original product version:   Microsoft SQL Server Management Studio
Original KB number:   4091777

Symptoms

Object Explorer intermittently hangs when you use SSMS. This issue applies to all versions starting from SSMS 2012.

This issue may occur anytime that Object Explorer is in focus (for example, when you click an item in the tree). However, this issue occurs only if all the following conditions are true:

  • SQL Server authentication is used.

  • The default database for the logon that is used to connect is not the master.

  • The SSMS version is 2012 or a later version.

  • Object Explorer is connected to the database engine.

    [!NOTE] Query windows do not experience this issue.

Cause

This issue is caused by a type of race condition that occurs between threads that are used by Object Explorer.

Resolution

To prevent this issue from occurring, use any of the following methods:

  • Method 1: Use Windows Authentication.
  • Method 2: Change the default database setting to the master database for the login.
  • Method 3: Change the SSMS connection string to request a connection to the master database.

For Method 2

To change the default database for the login, run the following commands by using a login that has the ALTER ANY LOGIN permission:

USE [master]
GO
ALTER LOGIN [YourLogin] WITH DEFAULT_DATABASE=[master]
GO

For Method 3

To change the SSMS connection string, follow these steps:

  1. In Object Explorer, click Connect, and then click Database Engine.

    :::image type="content" source="media/object-explorer-intermittently-crashes/database-engine.png" alt-text="Screenshot of the Connect menu of Object Explorer.":::

  2. In the Connect to Server window, click the Options button.

    :::image type="content" source="media/object-explorer-intermittently-crashes/connect-to-server.png" alt-text="Screenshot of the Connect to Server window.":::

  3. On the Connection Properties tab, enter master in the Connect to database field, and then click Connect.

    :::image type="content" source="media/object-explorer-intermittently-crashes/connection-properties.png" alt-text="Screenshot of the Connection Properties tab of the Connect to Server window.":::

Source: Microsoft Learn / IT Pro troubleshooting by Microsoft and contributors. Documentation licensed CC BY 4.0. Code samples are covered by the MIT License. Converted from Markdown, with links normalized and embedded media omitted.

资料来源与适用范围

资料来源
Microsoft Learn / IT Pro troubleshooting
适用范围
See source applicability · Source date 09/10/2020
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY 4.0 (documentation), MIT (code samples)

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。