FTP an iSeries Physical File in CSV format
Looking for an example project to get you started?
1 post
Page 1 of 1
- Support Specialist
- Posts: 91
- Joined: Thu Mar 05, 2009 3:49 pm
- Location: Ashland, NE USA
-
FTP an iSeries Physical File in CSV format
This project will convert a Physical file into a comma delimited CSV file, then FTP to your trading partner.
The physical file should be converted to something like a CSV file so that the receiving server will be able to read it.
In this example, we use of the iSeries CPYTOIMPF command.
This project will convert a Physical file into a comma delimited CSV file, then FTP to your trading partner.
The physical file should be converted to something like a CSV file so that the receiving server will be able to read it.
In this example, we use of the iSeries CPYTOIMPF command.
Code: Select all
<project name="Physical File CSV FTP" mainModule="Main" version="1.0" logLevel="debug">
<description>convert a Physical file into a comma delimited CSV file, then FTP.</description>
<module name="Main">
<createWorkspace />
<exec400 resourceId="DEV 54">
<command>
<![CDATA[CPYTOIMPF FROMFILE(SURVEYOR/DEMO) TOSTMF('${system.job.workspace}/FILE.CSV') STMFCODPAG(*PCASCII) RCDDLM(*CRLF)]]>
</command>
</exec400>
<ftp resourceId="Dev 54">
<put sourceFile="FILE.CSV" destinationFile="/demo/MYFILE.csv" type="auto" />
</ftp>
<deleteWorkspace />
</module>
</project>
1 post
Page 1 of 1