Click here to Skip to main content
15,881,803 members
Articles / Programming Languages / SQL
Tip/Trick

How to Copy SQL Table Into Excel and Other Formats

Rate me:
Please Sign up or sign in to vote.
3.67/5 (5 votes)
10 Jul 2013CPOL 23.9K   5   4
How to copy SQL table into Excel and other formats

Introduction

This post shows you how to take SQL table into Excel and other formats.

  1. Open ssms2012->databases->sample database.

    Image 1

  2. Click that export data. There is a new window open as shown below:.

    Image 2

  3. Choose the datasource, there are a lot of datasources dropdowns here:

    Image 3

  4. Choose the source database, here  dbo.sample is a source database.

    Image 4

  5. Here, you choose designation Database or other formats like oldb, excel formats.

    Image 5

  6. Then Excel file path.

    Image 6

  7. Select the first radio button for copy or second radio button for query to write the data, choose any one.

    Image 7

  8. Click next->select table you want to copy:

    Image 8

  9. If you want edit the columns means you have to use this window editmapping.

    Image 9

  10. You can check the preview for here:

    Image 10

  11. Click next.

    Image 11

  12. Finish.

    Image 12

  13. After you click finish, you can see files can be transferred like below:

    Image 13

  14. Go to->myDocuments, open the Excel file that you already created and all data comes to Excel sheet. That’s all.

    Image 14

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Database Developer NEELKANTH DIGITAL INFONET
India India
Production & Application DBA ,Asst Programmer

Comments and Discussions

 
QuestionHow can i Export SQL Server 2005 tables? Pin
Uganraj11-Jul-13 20:53
Uganraj11-Jul-13 20:53 
AnswerRe: How can i Export SQL Server 2005 tables? Pin
apachearun11-Jul-13 21:20
apachearun11-Jul-13 21:20 
GeneralMy vote of 1 Pin
nobodyxxxxx10-Jul-13 20:34
nobodyxxxxx10-Jul-13 20:34 
GeneralRe: My vote of 1 Pin
apachearun10-Jul-13 21:01
apachearun10-Jul-13 21:01 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.