Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 how to export to wrod, excel

Author  Topic 

Pasi
Posting Yak Master

166 Posts

Posted - 2014-05-01 : 13:15:33
Hi Gurus,

how do I export data from dB to excel , note, etc? is there a query to do this? does it have to be in form of tabular, like excel or can it be exported into other formats?
Thanks!
Pasi

sqlsaga
Yak Posting Veteran

93 Posts

Posted - 2014-05-01 : 15:29:20
You can either use import and export wizard or use SSIS to do this..

Right click on the database and select Tasks.
Click on Import Data / Export Data.
Select the source and destination as required.
And your requirement is done.

Visit www.sqlsaga.com for more t-sql code snippets and BI related how to articles.
Go to Top of Page

Pasi
Posting Yak Master

166 Posts

Posted - 2014-05-01 : 17:18:04
Thank you I 'll try that!

Pasi.
Go to Top of Page

jackv
Master Smack Fu Yak Hacker

2179 Posts

Posted - 2014-05-02 : 01:43:27
Hi Pasi, powershell can complete this task - output to either word or excel. It also give you programtic granular control. Read this post for a code example, which you can adapt to your purpose. http://www.sqlserver-dba.com/2013/05/sql-server-export-to-excel-with-powershell.html

Jack Vamvas
--------------------
http://www.sqlserver-dba.com
Go to Top of Page

Pasi
Posting Yak Master

166 Posts

Posted - 2014-05-02 : 11:31:10
Thank you jack!
Pasi
Go to Top of Page

jackv
Master Smack Fu Yak Hacker

2179 Posts

Posted - 2014-05-07 : 13:07:28
your welcome

Jack Vamvas
--------------------
http://www.sqlserver-dba.com
Go to Top of Page
   

- Advertisement -