How to Import a SQL Server Table Inside Excel Sheet? – Interview Question of the Week #273

Question: How to Import a SQL Server Table Inside Excel Sheet?

Answer: Well, the answer to this question is pretty straight forward and can be easily explained with the image.

You may follow the direction in the images here to see how you can pull a table from SQL Server inside Excel.

First of all open Excel and go to the Data tab.

How to Import a SQL Server Table Inside Excel Sheet? - Interview Question of the Week #273 insideexcel1

Now select the toolbar option Get External Data and select the option From Other Sources. Over here select the option which says From SQL Server which will bring up the following screen.

Solarwinds

How to Import a SQL Server Table Inside Excel Sheet? - Interview Question of the Week #273 insideexcel2

In this screen, you will have to enter your server name and authentication details. Once you provide them, click on the Next. Now it will bring you the screen as display here.

How to Import a SQL Server Table Inside Excel Sheet? - Interview Question of the Week #273 insideexcel3

In the above screen select database and from that database select one or more tables (views) for your database. Now it will bring you to the final screen.

How to Import a SQL Server Table Inside Excel Sheet? - Interview Question of the Week #273 insideexcel4

Over here, just give an appropriate name and click on the Finish. Once you select Finish it will bring up the following screen of the Import Data.

How to Import a SQL Server Table Inside Excel Sheet? - Interview Question of the Week #273 insideexcel5

Just click OK and you will see the following screen where the table which you have selected inside your Excel Sheet.

How to Import a SQL Server Table Inside Excel Sheet? - Interview Question of the Week #273 insideexcel6

Well, that’s it we are done. We have successfully imported a SQL Server table inside the Excel Sheet. It is also possible to import more than one table into various Excel Sheets.

Here are a few additional SQL Server Interview Questions:

How to Solve Error When Transaction Log Gets Full? – Interview Question of the Week #272

What is Stored in TempDB? – Interview Question of the Week #271

How to Check Database Performance Facets in SQL Server? – Interview Question of the Week #270

If you have any such interview questions and answers, please reach out to me via Twitter or Linkedin and I will be happy to post an interview question and answer with due credit to you. You can also hire me to help you tune your SQL Server and all the details for the same are here.

Reference: Pinal Dave (http://blog.SQLAuthority.com)

Solarwinds
,
Previous Post
How to Solve Error When Transaction Log Gets Full? – Interview Question of the Week #272
Next Post
What is Transactional Replication Supported Version Matrix? – Interview Question of the Week #274

Related Posts

Leave a Reply

Menu