Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Scheduling TSQL to Output file

Status
Not open for further replies.

Rajeswari

Technical User
Oct 6, 2001
17
IN
I am scheduling the job with TSQL("Select statement"), directs the output to the text file using "Advanced" option in Job step.

Scheduling works fine, but i want to format the output.
When i open the text file, it shows step name, executed time, number of rows affected,etc. I don't want these details since I want to export the output file to the table.
 
Somethings are not realy clear:
- Are you using bcp to export the date?
- Why do you think you need a text file?
- What kind of table you want the data to go to?
Let me know AL Almeida
NT/DB Admin
"May all those that come behind us, find us faithfull"
 

The advanced option in the Job Step allows you to create an AUDIT file to show the results of the step. That is what you are getting in the output. It will not contain the data from the Select statement.

You should be creating a DTS package to output the SQL to a text file. Then schedule the package to run as a Job. Alternately, you can create a job to run a batch file that executes BCP or OSQL to output the data to a file. Terry L. Broadbent
FAQ183-874 contains tips for posting questions in these forums.
NOTE: Reference to the FAQ is not directed at any individual.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top