Need help transfering iSeries DB2 file to PGP Windows program

Augusto needs your help. He writes: "I have an RPG ILE program that creates a file in my iSeries. The CL I am running controls that the file is ready to FTP to another location. To do this I have to transfer the file to a PC/Windows environment and then use a Windows-based PGP encryption program, which is the requirements at our company. "I tried different methods to not use an operator after the file is ready to be tranfer to the Windows environment, but they did not work. Could you please give an idea how can I use just one CL program or an RPG-ILE to submit this file to a Windows environment and then transmit it with the PGP encryption program based in the same Windows environment? Thanks much in advance for your help."

Answer Wiki

Thanks. We'll let you know when a new response is added.

There are 2 canned packages I know of that do this, by Linoma and by Patrick Townsend, and probably others. To get by on a budget, you could use the PGP-compatible freeware known as GPG (
I’ve written code that would do this in the past. My solution works with GPG, but if you already have PGP, it could easily be adapted to work with PGP.

Discuss This Question: 3  Replies

There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.
  • BigKat
    If you have an FTP server on the PC, you could have the iSeries CL FTP the file to the PC and then send a remote command to run a .BAT file on the PC to do your PGP processing. Look at help for quote and rcmd to see how you would send the remote command.
    9,460 pointsBadges:
  • McSick
    Use CPYTOIMPF to create a comma delimited version of your file and copy to /QDLS/.... then FTP /QDLS/... .csv file to PC network folder Or Use CPYTOSTMF command to copy the fixed file to /QDLS/... .dat or .txt file and then FTP /QDLS/... .dat or .txt file to PC network folder
    50 pointsBadges:
  • TomLiotta
    Note that any references to [/QDLS] should be taken to mean [/QNTC]. The /QDLS file system should not be used on any system at V5R1 or later. The /QNTC file system is a meaningful replacement choice because it automatically refers to shares that have been exported from Windows server systems. A more complete path would be [/QNTC/windowsservername/sharename/RemoteFileName.ext]. There is no need for FTP. The remote PC is written to directly. A requirement is matching user/password on both systems. The user/password on the Windows system is often created as a local user on that PC. The System i user can be created just for the purpose of transfers to/from Windows. Security APIs can be used to switch the job to the transfer user before the transfer, and then back to the job user after completion. The transfer itself would be essentially transparent. Tom
    125,585 pointsBadges:

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

Thanks! We'll email you when relevant content is added and updated.


Share this item with your network: