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
 Query Output

Author  Topic 

satheesh
Posting Yak Master

152 Posts

Posted - 2011-01-26 : 07:44:25
I am new to SQL Server.I have few questions.Any help would be highly appreciated.

I have set of query and need to run as a schedule job.

1.First,I want to know how to redirect the output of the query in Excel format to particular location.(ie.i need to store the result as excel file in a folder)

2.How to set a schedule task for that query.Need to be stored in the same folder.So i cant able to set a same file name for the result.

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2011-01-26 : 11:17:54
1. use OPENROWSET or bcp
see
http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=49926

2.you need to add a sql server agent job

see
http://databases.about.com/od/sqlserver/ss/sql_server_agent_3.htm

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page
   

- Advertisement -