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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DTS package to crate a CSV file in a loop

Status
Not open for further replies.

Jeet2004

MIS
Jun 29, 2005
96
US
Hi,
Here's what i need to do.
1.Find out the BatchNames for a particular day.
2.For each BatchName create a CSV file of that batchName wiht the details of that batch with specific column headings.
3.Ftp these files (ftp can be done one file at a time or all the files in a batch)

All i know is the step1 but dont have a clue how to do step 2 and 3
I would higly appreciate if some one could guide me with this.
Thanks.
 

You may consider executing this function through VB script.

For every batchname
Call DTS com component

Pass the Batchname and csv filename to the DTS component. Call a sql statement to pull the batch data out of the database and create an XLS / text (CSV file).

The dts component will have to called for each batchname to create a csv file.

Hope that gets you started.

JB
 
can you suggest me a code sample to look at
Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top