× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.


  • Subject: Re: Transferring files from NT to System/36
  • From: "Peter Dow" <pcdow@xxxxxxxxx>
  • Date: Mon, 8 Nov 1999 11:15:33 -0800

If you're more comfortable with the PC side, you can use Client Access.
Here's a sample PC batch file to do a generic transfer from the PC to an
AS/400. It assumes you have previously downloaded the destination AS400 file
in order to create the .FDF file. If you're transferring to files with
different names but the same fields, you can replace the "echo %3.FDF>>
%1.TFR" line with the specific .FDF file name instead of %3.

PUTFILE.BAT
===========
@echo off
rem Creates a request to transfer file %1 from the PC to library %2 file %3
member %4 on an AS/400 %5

 rem %1 = PC file name
 rem %2 = AS/400 library
 rem %3 = AS/400 file
 rem %4 = AS/400 member
 rem %5 = AS/400 system name

rem Create xxx.TFR
 echo TRFRPC> %1.TFR
 echo.>> %1.TFR
 echo TO          %2/%3(%4)>> %1.TFR
 echo %1>> %1.TFR
 echo 21>> %1.TFR
 echo %4.FDF>> %1.TFR
 echo 12  921>> %1.TFR
 echo.>> %1.TFR
 echo.>> %1.TFR
 echo.>> %1.TFR
 echo SYSTEM      %5>> %1.TFR
 echo 0>> %1.TFR
 echo PROPS       00011>> %1.TFR
 echo.>> %1.TFR

rem Run %1.TFR
        rfrompcb /S %1.TFR

Or you can use FTP on the AS/400 side. The basic idea is:

            OVRDBF     FILE(INPUT) TOFILE(srclib/srcfile) MBR(srcmbr1)
            OVRDBF     FILE(OUTPUT) TOFILE(srclib/srcfile) MBR(srcmbr2)
            FTP        RMTSYS(remotesysname)
            DLTOVR     FILE(INPUT)
            DLTOVR     FILE(OUTPUT)

Before doing this, you need to load srclib/srcfile(srcmbr1) with the FTP
script for the particular file you're going to download.

userid password
ASCII
GET c:\temp\testfile library/file.member (REPLACE
QUIT

Output looks like this:

0001.00 Output redirected to a file.
0002.00 Input read from specified override file.
0003.00 Connecting to host name REMOTESYSTEMNAME at address xxx.xxx.xxx.xxx
using port 21.
0004.00 220-QTCP at xxx.xxx.xxx.xxx
0005.00 220 Connection will close if idle more than 5 minutes.
0006.00 215  OS/400 is the remote operating system. The TCP/IP version is
"V3R1M0".
0007.00 Enter login ID (userid):
0008.00 331 Enter password.
0009.00 230 userid logged on.
0010.00 250  Now using naming format "0".
0011.00 257 "library" is current library.
0012.00 Enter an FTP subcommand.
0013.00 > GET c:\temp\testfile library/file.member (REPLACE
0014.00 200 PORT subcommand request successful.
0015.00 150 Retrieving member MEMBER in file FILE in library LIBRARY
0016.00 250 File transfer completed successfully.
0017.00 498070 bytes transferred in 171.009 seconds. Transfer rate 2.913
KB/sec.
0018.00 Enter an FTP subcommand.
0019.00 > QUIT

Note that you need to have a program read the output looking for the "250
File transfer completed successfully." message to determine if it was
successful.

HTH
Peter Dow
Dow Software Services, Inc.
909 425-0194 voice
909 425-0196 fax

From: <keith.nolan@dubport.ccs.ie>
> I've had a few replies to my Query But I don't Have a definitive answer
could someone please Help me with this one it has me pulling my hair out.
The original Query is below.  If anyone thinks I should use FTP on the AS400
to take the files down please show me an example of the script I could
use.....


> +---
> | This is the Midrange System Mailing List!
> | To submit a new message, send your mail to MIDRANGE-L@midrange.com.
> | To subscribe to this list send email to MIDRANGE-L-SUB@midrange.com.
> | To unsubscribe from this list send email to
MIDRANGE-L-UNSUB@midrange.com.
> | Questions should be directed to the list owner/operator:
david@midrange.com
> +---



__________________________________________________
Do You Yahoo!?
Bid and sell for free at http://auctions.yahoo.com

+---
| This is the Midrange System Mailing List!
| To submit a new message, send your mail to MIDRANGE-L@midrange.com.
| To subscribe to this list send email to MIDRANGE-L-SUB@midrange.com.
| To unsubscribe from this list send email to MIDRANGE-L-UNSUB@midrange.com.
| Questions should be directed to the list owner/operator: david@midrange.com
+---

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.