Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Outputting a file using MSSS 2008 R2

Posted on 2014-02-04
1
Medium Priority
?
331 Views
Last Modified: 2014-02-07
I'm currently using bcp to putput a csv file each day and want to know if there is a much better way to do this.   I'm using MS SQL Server Management Studio 2008 R2.

THanks .......

Joel
0
Comment
Question by:jtbrown1111
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 40

Accepted Solution

by:
lcohan earned 2000 total points
ID: 39833544
You can use SSIS to do that easily
http://social.msdn.microsoft.com/Forums/sqlserver/en-US/41293231-1d96-4315-8884-d3a89abc2f66/how-do-i-export-to-csv-in-ssis?forum=sqlintegrationservices


or direct from SQL Query like below:

exec master..xp_cmdshell N'sqlcmd -E -Q"set nocount on; select * from DB_Name.dbo.TableName;" -s"," -W -o"c:\output.csv"'
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When trying to connect from SSMS v17.x to a SQL Server Integration Services 2016 instance or previous version, you get the error “Connecting to the Integration Services service on the computer failed with the following error: 'The specified service …
What we learned in Webroot's webinar on multi-vector protection.
Via a live example, show how to backup a database, simulate a failure backup the tail of the database transaction log and perform the restore.
Viewers will learn how the fundamental information of how to create a table.

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question