"Is The FTP Reference Guide found in the IBM Books?"
Peters: Several chapters in the OS/400 TCP/IP Configuration and Reference V4R4 (SC41-5420-03) are devoted to configuring and using FTP. Examples are also provided."
Osler: Actually, the online IBM InfoCenter is the best source of current FTP documentation, though most of us also cling tightly to old copies of the V4R3 TCP/IP manual. The InfoCenter and lots of other good stuff can be accessed through the iSeries Support.
"How do I use a port other than 21?"
Peters: I can't find any access to change the control port for FTP on the iSeries/400 at least at release V4R5.
Osler: I'm not sure if this also works at V4R5, but at V5R1, you can change the control and data ports for FTP by changing the service table entries in the TCP/IP configuration. Use Option 21 on the CFGTCP menu. Be careful - be sure to copy the descriptions carefully.
"What about the security about FTP?"
Peters: Access to the iSeries for FTP users is the same as for other users -- user ID and password. You can also allow anonymous access. For other security considerations you may create an FTP exit program to perform a variety of security screening or logging.
Osler: At V5R1, many of these functions can be configured in Ops Navigator. Right-click on the system name, then take the option for Application Administration. Click on the tab for 'Host Applications', then expand the listing for 'AS/ 400 TCP/IP Utilities'. This will lead to a number of panels that can be used to configure FTP security.
"Do you have examples of how to build the input "file in a CL"?
Peters: CL is not capable of writing to a database file. You would have to write a HLL program.
Osler: There is a QUSRTOOL utility that lets you write to a source physical file. This has been used in the past to create the FTP utilities that can dynamically update the batch FTP command file.
Can you tell us how to get logs of FTP activity?
Peters: See the example above for iSeries as the client. If a PC is the client, you can use one of the many FTP utilities that allow you to log FTP activity.
Osler: If you want a joblog for an FTP server job - you can issue a QUOTE RCMD DSPJOBLOG command from the client before ending the FTP session. This will dump the joblog of the server to a spool file.
What different methods are there in the market that can be used to upload files to/from Excel to AS/400 with ease of use?
Peters: You can use CA file transfer to load iSeries files directly to or from Excel. There are other utilities that also perform the same function. My company has such a product. You can see it here.
Osler: You may want to investigate using CPYFRMIMPF and CPYTOIMPF commands. They can be used to exchange .csv files with Excel, and can be used to export man-readable data from iSeries database files in a variety of different formats. These are documented in the CL Command Reference and InfoCenter.
How do you convert ASCII numeric data to non-packed numeric fields on the AS/400? We want to convert ASCII minus signs to EBCDIC.
Peters: When we created the utility that transfers data, we had to perform the packed data and minus sign translation with a HLL program. Quite complicated, too.
Osler: Again, this is handled by the CPYTOIMPF and CPYFRMIMPF and a FDF. It will convert packed data, etc., into man-readable fields, and from man-readable into the format specified by FDF and DDS.
================================== MORE INFORMATION ON THIS TOPIC ==================================
The Best Web Links: tips, tutorials and more.
Ask your programming questions--or help out your peers by answering them--in our live discussion forums.
Ask the Experts yourself: Our application development gurus are waiting to answer your programming questions.
This was first published in July 2002