Object status icons and visualization

Applies to
ApexSQL Source Control

Summary
This article explains object status icons from the Object Explorer pane inside SQL Server Management Studio (SSMS) when working with ApexSQL Source Control

Description

Dedicated model

When working in the Dedicated model, there are two different icons that can be shown in the Object Explorer pane. As soon as a database is linked to the repository, all objects that are selected to be version controlled in the Object filtering step will have the default “version controlled” icon in the Object Explorer pane:

When the object is displayed with this icon it means that:

  • The object has been added to version control during the linking process, or

  • The object is initially committed to the repository and the current version of an object in a database is the same as the latest version of the same object on the repository

When the user modifies any version controlled object, its status icon will be changed in the Object Explorer pane to a check mark:

The following table shows object status icon of an edited object, when working in the Dedicated model:

Object status
Object Explorer icon
Default
Edited

Shared model

Default state

Similar to the Dedicated model, the default icon is the same, and represents one of the following:

  • The object has been added to be version controlled during the linking process, or
  • The object is initially committed to the repository and the current version of an object in a database is the same as the latest version of the same object on the repository

In addition to this, if an object is initially committed and its state is presented as a default in the Object Explorer pane, it means that it is not yet edited by any user, nor it is checked out or locked:

Edited

When an object is edited, its icon in the Object Explorer pane will be displayed as green to that user:

The other developers will see the object with a red version controlled icon:

Checked out

The previous scenario describes when an object is edited, without being checked out or locked previously. In the case when an object is checked out, the icon for that object in the Object Explorer pane will be displayed as a check mark:

The other developers will also see a check mark but it will be grey:

Checked out and edited

If the user who checked out an object also modifies it, the icon of the checked out and modified object appears as a green check mark:

To the other developers on the team, this same object has a red check mark:

Locked

If you lock an object, the icon in the Object Explorer pane will have a blue lock icon:

The other developers will see it as a grey lock:

Locked and edited

If you edit the object you have checked out and locked, it will be shown with a green lock icon:

The other developers will see it as a red lock icon:

Quick tip icon

Quick tip:

Locked object cannot be edited, nor can the lock operation can be overridden

To summarize the above, the following is a table that represents all the object statuses from a perspective of the user who performed the specific operation (User A), as well as from a perspective of another user (User B) who has the same database linked using the Shared model:

Object status
User A
User B
Default
Edited only (without check out or lock)
Checked out (not edited)
Checked out (and edited)
Locked (not edited)
Locked (and edited)

Object status form

To avoid searching for the particular object in the Object Explorer pane in order to find out its status, the Object status form can be used to investigate which objects are not in a “default” state. To access the Object status form, right click on a linked database in the Object Explorer pane, and select the Object status command from the context menu:

The Object status form contains all objects from a database that are selected to be version controlled:

The appropriate column will contain a checkmark to describe if an object is being checked out, edited or locked. Besides the information about the object status, the Object status form contains information about the exact user who changed the status of the particular object.

Overriding Check outs

Since the Check out operation can be overridden, when a user performs a Check out operation against an object that is already checked out, the object status icon will be changed. The following table shows how the check out icon looks like before and after the Check out operation is overridden, and in the case where an object is edited and not edited, to the user who is overriding the Check out operation:

First developer perspective

 
Not edited
Edited
Before check out
After check out

From a perspective of the user whose check out is overridden, the following table shows how the object status icon of a checked out object will be changed, depending on if an object is edited or not:

What other developers will see

Not edited
Edited
Before check out
After check out

Q: Can a check out or lock operation be performed against already edited object?

A: Yes, Check out and Lock operations can be performed against an edited object as well as against an object that is not edited.

Q: What happens with objects status when relinking a database?

A: If one user unlinks a database, while at least one more user has the same database linked in the shared model, the information about which objects are checked out or locked will not be removed. Any object that is being edited by the user who relinked a database will be shown in the Action center tab, including the information about which user modified them.

The information about object status will be removed in case the last user unlink the last database linked on a SQL Server instance.

Q: Is the Object status form available to all the users who have a database linked?

A: The Object status form is available to all the users that have at least select permission against the ApexSQL_SourceControl.Objects table.