0 pts.
 Copying Spoolfiles
Hi, I would like to know, How to copy spoolfiles from one AS400 machine to another AS400 machine? Thanks in Advance Rama Krishna

Software/Hardware used:
ASKED: April 10, 2007  5:41 AM
UPDATED: January 8, 2010  7:46 AM

Answer Wiki:
1) Create a file to transfer the spool file data on the source system. RCDLEN is (at least) 1 char larger than width of report. ? CRTPF FILE(library/file) RCDLEN(length) 2) Save the spool file data to the transfer file on the source system. ? CPYSPLF FILE(splfname) TOFILE(library/file) JOB(jobnbr/user/jobname) SPLNBR(splfnbr) CTLCHAR(*FCFC) MBROPT(*REPLACE) 3) Send the transfer file from the source system to the target system via FTP, SAVF transfer, etc. 4) Set printer file to have the proper attributes (QSYSPRT for standard 132 char or less, otherwise create a printer file with the correct PAGESIZE and OVRFLW) and copy the spool file data to it from the transfer file. ? OVRPRTF FILE(prtf) OUTQ(outq) FORMTYPE(formtype) USRDTA(userdata) HOLD(hold) SAVE(save) SPLFNAME(splfname) CTLCHAR(*FCFC) ? CPYF FROMFILE(library/file) TOFILE(prtf) ================================================================ SNDNETSPLF can be used if SNA Distribution Services is configured. This is what option 1=Send does from a WRKSPLF list. More often nowadays, SNDTCPSPLF can be used to copy a spooled file to an output queue on another AS/400. The receiving system needs to have the proper server started - STRTCPSVR *LPD -- in order to get the request across. The command can also send spooled files to other kinds of systems including PCs. If automation is needed, remote output queues work through the same LPR/LPD protocol that is used by SNDTCPSPLF. Tom
Last Wiki Answer Submitted:  January 8, 2010  7:46 am  by  BigKat   7,185 pts.
All Answer Wiki Contributors:  BigKat   7,185 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _


 

Have you tried Send Network Spooled File (SNDNETSPLF). If your AS/400?s are on the same network and you are enrolled in the directories you can use this command easily. Conversely, you can access this command by a WRKSPLF and option 1 next to the file you wish to transfer. Required parameters are USERID and ADDRESS.

 100 pts.