I am using SQL Server 2008, I want to generate a CSV file using a select query. I am aware of SQL CMD and BCP but below are some of my constraints with it.
- There are a lot of parameters in my query and I have multiple queries that need to run sequentially/ and ability to rollback.
- I am running a query from within a Workflow product which doesn't provide an option to run a command See here(enter image description here )
- Don't have the luxury of visual studio or coding
I found an example for MySQL below, I'm looking one for a SQL Server 2008.
select * into outfile 'd:/report.csv' fields terminated by ',' from tableName;
Thanks in advance. D