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
 SQL Server 2000 Forums
 Import/Export (DTS) and Replication (2000)
 Automate/scheduling text file from FTP site to SQL

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2004-12-02 : 08:24:03
James Goh writes "I had to automate a daily/monthly extract process from a FTP site to SQL server. A new filename is given each day for the daily files and for the monthly files as well.
How do I auotmat it since the filename changes everday for the daily files and the monthly files as well?
Is DTS able to handle this?"

robvolk
Most Valuable Yak

15732 Posts

Posted - 2004-12-02 : 08:27:34
Nigel has some code on FTP functions that do not use DTS:

http://www.nigelrivett.net/

DTS's FTP functionality is pretty limited. Windows comes with a command-line ftp utility (called, surprisingly, ftp) that is far easier to program and is much more flexible, as Nigel's code will demonstrate.

And if the files are just plain text files, bcp and BULK INSERT can import them very nicely, and again they are both more flexible and easier than DTS. Books Online can tell you more, and Nigel's site has examples of bcp too.
Go to Top of Page
   

- Advertisement -