title: Transfer a file from AS400 to another machine in the same network
body: <p>I am trying to export the data of a table on AS400 to another machine through iSeries commands but I am stacked in the middle of the process. I have a stored procedure in which I create the CSV file but after completion I need to transfer this file to another machine (which is of course connected to the AS400).</p>
  
  <p>In the stored procedure, I used the <code>CPYTOIMPF</code> command to export table data to CSV and I wrote the file on the AS400 file system. I don't know if there is an option to write the file directly to another machine.</p>
  
  <pre><code>CALL QSYS2.QCMDEXC(
   'CPYTOIMPF FROMFILE(LIBRARY/TABLE) TOSTMF('/QIBM/UserData/TestFolder/2.CSV') STMFCODPAG(*PCASCII) RCDDLM(*CRLF)'
  );
  </code></pre>
  
  <p>This step is completed and the file is written on that directory.</p>
  
  <p>Now I need to transfer this file to a web server that is connected to AS400 without after the above command is completed.</p>
  
  <p>How can I do that?</p>