Page 1 of 1

Can i use FTP Enterprise Stage

Posted: Mon Nov 17, 2008 9:28 pm
by pradkumar
Hi ,

I have a requirement -- One of the source system will produce a file daily (.csv) and place it in a designated directory on their FTP site.I need to create a method to automatically transfer this file via FTP and place it in a local directory on my sever.( I will also need to log audit data and send email in case of transfer failure)

Can i achieve this requirement using FTP Enterprise stage? can any one suggest an idea on this process.

Thanks a lot

Posted: Tue Nov 18, 2008 1:33 am
by ray.wurlod
No. The FTP stages do not transfer files. They transfer byte streams; they read the file on the remote server and stream the bytes directly into your DataStage job.

Better approach is to create a script to effect the file transfer, and use the exit status of that script to trigger appropriate action.

Posted: Tue Nov 18, 2008 8:30 am
by chulett
So, yes if you then take that byte stream and use the Sequence stage to write it to disk. However, with all of the possible complications with metadata and inadvertent transformations that entails, I second Ray's advise to script something via traditional command line ftp.

You'll need a script regardless to handle the "is the file there" part. That or a WaitForFile stage in a Sequence job.