Error while using FTP enterprise stage to read a record

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
prindu1302
Participant
Posts: 6
Joined: Thu Mar 16, 2006 9:27 am
Location: Chennai-India

Error while using FTP enterprise stage to read a record

Post by prindu1302 »

While I try to FTP a file using FTP enterprise stage from the specified path to my server, the job aborts giving an error that the file name does not exist. But If I create a file in the root directory of the remote server with the same name of the file [not required to be of the same format] and I try to FTP, my job runs successfully and fetches all the records from the remote path specified. Is there any specific setting that has to done?
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

The URI property is documented as follows.

Type: Pathname
Name of the URI to get or put the file from or to.It can be more than one occurence. Supports limited wild carding. The expected syntax is ftp://hostname[:port]/URIpath


You need to make sure that the URI path points to where your file actually is. If you simply include the file name, it will expect to find the file in the FTP root directory.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
prindu1302
Participant
Posts: 6
Joined: Thu Mar 16, 2006 9:27 am
Location: Chennai-India

Post by prindu1302 »

I have set the URI followed by the open command where I have specified the remote path.
In the URI I have set the property as below:
ftp://<RemoteServername>/<Filename>
In the open command I have specified the remote path where the file resides as shown below:
cd /<RemotePath>
Do we have to have a file with the same name in the root directory of the remote server for us to ftp the file from the remote server path to our local server?
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

It should not be necessary. The cd command should suffice.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
prindu1302
Participant
Posts: 6
Joined: Thu Mar 16, 2006 9:27 am
Location: Chennai-India

Post by prindu1302 »

But it is not working if I remove the file from the root directory.Is it like some kind of bug or is it a mistake with the settings that i have done
sud
Premium Member
Premium Member
Posts: 366
Joined: Fri Dec 02, 2005 5:00 am
Location: Here I Am

Post by sud »

prindu1302 wrote:But it is not working if I remove the file from the root directory.Is it like some kind of bug or is it a mistake with the settings that i have done
I have used direct path in the location property and it works (cant access DS right now hence cant tell u the exact name of the property). In my case i put a path like /home/<name>/<folder>
It took me fifteen years to discover I had no talent for ETL, but I couldn't give it up because by that time I was too famous.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

sud wrote:I have used direct path in the location property and it works (cant access DS right now hence cant tell u the exact name of the property). In my case i put a path like /home/<name>/<folder>
Was this in an FTP Enterprise stage?
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply