The Server Explorer in Visual Studio

CodeGuru content and product recommendations are editorially independent. We may make money when you click on links to our partners. Learn More.

Introduction

The Server Explorer in Visual Studio needs little introduction for many a programmer; but for newbie, it might need some proper explanation; hence, this article. Let me start at the beginning.

What Is the Server Explorer?

The Server Explorer is a shortcut to accessing servers, either installed on the system, or connected to the system. These servers are usually database servers such as SQL Server. By accessing the server, you access all the databases on the specific server, and then you can build the connections needed inside your program, for your program. You also can get access to SharePoint servers. I will touch on SharePoint a little bit later, but for now, I will concentrate on using the Server Explorer with an SQL Server, and then move on to the inner workings of the Server Explorer.

How Does the Server Explorer Work?

As said, the Server Explorer provides quick access to the connected database servers. With the Server Explorer, you can set up queries for use in your program. A default instance of the Server Explorer looks like the following:

ServExp1
Figure 1: The Server Explorer

You can see in Figure 1 that there are three items listed:

  • Data Connections
  • Servers
  • SharePoint Connections

Data Connections

As the name implies, the Data Connections item allows you to add, edit, and remove data connections within your program. To connect to a database on a server, follow these steps:

    1. Click the Connect to Database button on the Server Explorer’s toolbox.ServExp2
      Figure 2: Add Connection
  1. You simply enter (or choose) the server name, choose the database name, and click OK.
  2. The connection will be entered into the Server Explorer window. It’s as simple as that.

Servers

The Servers item gives you access to all the servers connected to your computer, as displayed in Figure 3:

ServExp3
Figure 3: Servers

Apart from seeing the servers, you get access to several tools as well. These tools assist in checking the performance of your queries as well as the event logs. You can have a look here for a detailed explanation on Performance Counters.

SharePoint Connections

Earlier, I spoke briefly about SharePoint. According to Wikipedia, SharePoint is basically a web application platform. SharePoint integrates content management and document management capabilities. SharePoint is a set of web technologies that provides intranet portals, document management, collaboration, social networks, websites, enterprise search, and business intelligence. For a detailed list of SharePoint capabilities and what you can do with SharePoint, have a look here.

More Reading

You might find the following articles quite helpful in your ventures inside the world of databases:

Conclusion

I hope you have enjoyed today’s article. Until next time, cheers!

Hannes DuPreez
Hannes DuPreez
Ockert J. du Preez is a passionate coder and always willing to learn. He has written hundreds of developer articles over the years detailing his programming quests and adventures. He has written the following books: Visual Studio 2019 In-Depth (BpB Publications) JavaScript for Gurus (BpB Publications) He was the Technical Editor for Professional C++, 5th Edition (Wiley) He was a Microsoft Most Valuable Professional for .NET (2008–2017).

More by Author

Get the Free Newsletter!

Subscribe to Developer Insider for top news, trends & analysis

Must Read