Using Data Transformation Services, part 7: Transferring Files with DTS - File Transfer From FTP Site to
(Page 2 of 4 )
Create a new package in the DTS designer and add an FTP Task as shown in the next picture.

It adds an icon to the designer pane. Right click this icon. From the pop-up menu, click on properties to bring up the window shown in this picture. For the Description, you may choose to type whatever is appropriate. There are two options for the Source drop-down, internet being the default. It can be changed to a directory. For the present we keep the default and discuss the FTPing from directory to directory in the next section.
For the FTP site, you can enter either the localhost or the IP address. In this case, 127.0.0.1. A remote site can also be referenced for example, as ftp.Acme.com (fictitious site). However, you should have login information to connect to the site. Depending on the size and number of files to be transferred, you may have to retry several times. You can set this up in the Number of retries box with the dial. For the Directory, you may browse to a location. This location can be a local directory, as shown in this picture, or a shared drive using either a drive name, or a UNC path, such as \\nechost\ftproot.

Next click on the tab files. If the internet site information is wrong or if the authentication supplied is not correct, you get the following error. You must rectify the information and try again.

If the connection is successful, you should see the files and directories in the C:\FTPSend directory as shown in this picture. If you do not have List permissions to the <DIR> in the Source pane of the File Transfer Protocol Task properties window, you may not be able to expand the <DIR> folder to transfer the files therein.

Now, just highlight the files you want to FTP and click the > button. You may FTP all files using the >> button. If the file that you are trying to FTP already exist in the Destination folder, and you have not checked the checkbox marked Overwrite, you may get the following error.

If the file information is correct, you will get the following message when you execute the package (review previous tutorials for executing a package). The file gets transferred to the indicated directory on the hard drive.

Next: File transfer from directory to directory >>
More MS SQL Server Articles
More By Jayaram Krishnaswamy