FTP file to Mainframe

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
danddmrs
Premium Member
Premium Member
Posts: 86
Joined: Fri Apr 20, 2007 12:55 pm

FTP file to Mainframe

Post by danddmrs »

Attempting to FTP a file to the mainframe I encountered a problem with fields being Right Justified. Searches of the forum seemed to have one common resolution - FTP from the command line. Worked perfectly - thanks.

If it's possible I would still like to FTP directly from DS to the Mainframe. Aside from the Right Justify issue this was great. I wasn't chewing up space on the server, I didn't need to get tech support involved with the FTP process, in short it was looking pretty sweet.

If anyone has any suggestions on how to get the FTP to leave the format as is I would appreciate the feedback.

I believe there were several references to using the FTP Plug-in to read files and not for moving them. Maybe what I'm looking for is an FTP Plug-out and I'll need to add that to the wish list.

Thanks.
Richard Schneider
sud
Premium Member
Premium Member
Posts: 366
Joined: Fri Dec 02, 2005 5:00 am
Location: Here I Am

Re: FTP file to Mainframe

Post by sud »

I think since you have the ftp command now, you can create a wrapper stage which will give you exactly what you want ... the functionality you get in unix plus the comfort of invoking from datastage.
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.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Rather than define all that metadata in the FTP Stage (which I assume is what we're discussing here) what I've found works best is to define your record as one long field, no quotes, no nothing added. This is the closest you'll get in DataStage to the functionality of the command line ftp process.

That way it puts exactly what it gets. Assuming you've landed your data first. If you are building it on the fly you could end up concatenating the record, but you'd need to add the delimiters and quoting and whatever else you needed to be there on the other side.
-craig

"You can never have too many knives" -- Logan Nine Fingers
danddmrs
Premium Member
Premium Member
Posts: 86
Joined: Fri Apr 20, 2007 12:55 pm

Post by danddmrs »

Thanks Craig. The FTP works perfectly.

Richard.
Post Reply