Work with Object Viewer

Object Viewer is a visual tool that provides detailed information about database objects, such as databases, tables, views, stored procedures, triggers, indexes, and constraints. It lets you view and manage object properties, dependencies, and related details without opening a separate editor. The tool also lets you view DDL statements and edit data.

Key features of Object Viewer:

  • Viewing detailed properties of a database object.
  • Accessing object structure, indexes, constraints, and triggers.
  • Displaying the DDL script for a database object.
  • Navigating to related objects in the database.
  • Viewing components, such as table columns or keys.
  • Modifying table or view data in a visual Data Editor.

Open Object Viewer

To open Object Viewer, do one of the following:

  • On the top menu, select View > Object Viewer.
  • Press F7.

Object Viewer includes the following sections:

  • Object Viewer toolbar.
  • Folder navigation bar.
  • Object Details View.

Object Viewer

Note

The Object Details View varies based on the selected object type or its element.

Object Viewer toolbar

The Object Viewer toolbar provides a set of controls to perform the following actions:

Icon Name Description
Connection Connection Select the required connection from the list. To create a new connection, select New. This opens the Database Connection Properties dialog, where you can specify connection details to create a connection. For instructions, see How to connect to a SQL Server database.
Properties Properties Open the properties grid for the selected database object or its element.
Text Text Display the code of the object you open in the grid.
Data Data Open Data Viewer where you can view and manage data.
Back and Forward Back and Forward Navigate to the previous or next object type in the folder navigation bar.
Up Up Navigate up one directory.
Synchronize with Database Explorer Synchronize with Database Explorer Update Object Viewer to reflect the current state of Database Explorer.
Refresh Refresh Refresh the grid.
Stop Refresh Stop Refresh Cancel an ongoing refresh operation.

Folder navigation bar

The folder navigation bar represents a static breadcrumb menu.

To navigate between folders, on the Object Viewer toolbar, use Back, Forward, or Up.

Object Details View

The Object Details View displays a grid containing information about the selected database object or its elements. The properties shown in the grid vary depending on the selected object.

The folder structure expands at multiple levels, following a hierarchy from a connection down to individual elements within a database object. For example, the navigation path may be: Connection name > Database Name > Tables > Table Name > Columns > Column Name.

The following table describes the Object Details View for different object levels:

Name Description
Connection Displays all databases available on the selected server, along with their properties, such as database name, owner, compatibility level, creation date, user access settings, etc.
Database name Displays folders for different database object types and the number of objects in each category. Objects are grouped into categories, such as Tables, Views, Synonyms, Programmability, External resources, Service Broker, Storage, and Security.
Group of database objects (for example, Tables) Displays all objects within the selected group and their properties. For example, if you select Tables, the grid lists all available tables along with their details. The properties displayed vary based on the object type.
Specific database object name Displays all elements associated with the selected object. For example, selecting HumanResources.Employee from the Tables group shows all columns and their properties.
Specific element of the database object Displays detailed properties of a specific element. For example, selecting the JobTitle column within the HumanResources.Employee table shows properties specific to that column.

Object Viewer - Example

You can perform operations directly from any grid using the shortcut menu. To do this, right-click the row and select the shortcut menu option.

Note

The available shortcut menu options depend on the selected grid and object type.

Object Viewer - Example: Table grid

View DDL statements

To view a DDL statement of a specific object:

1. In the grid, double-click the required object.

2. On the Object Viewer toolbar, select Text.

Object Viewer - View DDL statements

Edit database object data

To edit database object data:

1. In the grid, double-click the required object.

2. On the Object Viewer toolbar, select Data.

3. In the grid, right-click the row to select the shortcut menu option.

Object Viewer - Edit database object data