Command reference / spool

SNDTCPSPLF

Send TCP/IP Spooled File

Sends a spooled file to a printer queue on a remote system with TCP/IP, using the LPR/LPD protocol. The remote system is named directly or by internet address, and the printer queue is the name that system's LPD uses. A file being written cannot be sent, and an inactive TCP/IP stack fails the send.

Allowed environments: *ALL. Positional parameters: 3.

Parameters

RMTSYS Remote system

Specifies the remote system that receives the spooled file, by host name, DNS name or internet address. This is a required parameter.

Type
*CHAR
Required
Yes
Length
255
Case
Uppercase

Suggested / special values: *INTNETADR

*INTNETADR
The remote system is named by the INTNETADR parameter.

PRTQ Printer queue

Specifies the name of the printer queue on the remote system, as its LPD server knows it. This is a required parameter.

Type
*CHAR
Required
Yes
Length
128
Case
Uppercase

FILE Spooled file

Specifies the spooled file to send. This is a required parameter.

Type
*NAME
Required
Yes
Length
10
Case
Uppercase

JOB Job name

Specifies the job that created the spooled file.

Type
*QUAL
Required
No
Default
*
Case
Uppercase

Suggested / special values: *

*
The job that issued the command produced the spooled file.
Qualified parts (object, then library; write LIBRARY/OBJECT)

Job name Job name

Type
*NAME
Required
No
Length
10
Case
Uppercase

User User

Type
*NAME
Required
No
Length
10
Case
Uppercase

Number Number

Type
*CHAR
Required
No
Length
6
Case
Uppercase

SPLNBR Spooled file number

Specifies the number of the spooled file that has the specified file name.

Type
*INT4
Required
No
Default
*ONLY
Range
0 to 999999
Case
Uppercase

Suggested / special values: *ONLY, *LAST, *ANY

*ONLY
Only one spooled file in the job has the specified file name.
*LAST
The highest-numbered spooled file with the specified file name is sent.
*ANY
The spooled file number is not used to select the file.

JOBSYSNAME Job system name

Specifies the system where the job that created the spooled file ran.

Type
*NAME
Required
No
Default
*ONLY
Length
10
Case
Uppercase

Suggested / special values: *ONLY, *CURRENT, *ANY

*ONLY
There is one spooled file matching the other identifying values.
*CURRENT
The spooled file created on the current system is sent.
*ANY
The job system name is not used to select the file.

CRTDATE Spooled file created

Specifies the date and time the spooled file was created, after the other identifying values are matched.

Type
*ELEM
Required
No
Default
*ONLY
Case
Uppercase

Suggested / special values: *ONLY, *LAST

*ONLY
There is one spooled file matching the other identifying values.
*LAST
The spooled file with the latest creation date and time is sent.
Elements in order

Creation date Creation date

Type
*DATE
Required
No
Case
Uppercase

Creation time Creation time

Type
*TIME
Required
No
Default
*ONLY
Case
Uppercase

Suggested / special values: *ONLY, *LAST

DESTTYP Destination type

Specifies the type of the remote destination, which decides how the data is formatted.

Type
*CHAR
Required
No
Default
*AS400
Length
7
Case
Uppercase

Allowed values: *AS400, *PSF2, *OTHER

*AS400
The destination is an IBM i system; its host print transform is used.
*PSF2
The destination is a PSF/2 print server.
*OTHER
The destination is another type of system, which receives the data as it is.

TRANSFORM Transform SCS to ASCII

Specifies whether the host print transform converts the SCS data stream to ASCII for the remote printer.

Type
*CHAR
Required
No
Default
*YES
Length
4
Case
Uppercase

Allowed values: *YES, *NO

*YES
The data is transformed with the manufacturer type and model and workstation customizing object.
*NO
The data is sent without host print transform.

USRDTATFM User data transform

Specifies a user data transform program that formats the data instead of the host print transform. Not allowed with TRANSFORM(*YES).

Type
*QUAL
Required
No
Default
*NONE
Case
Uppercase

Suggested / special values: *NONE

*NONE
No user data transform is used.
Qualified parts (object, then library; write LIBRARY/OBJECT)

User data transform User data transform

Type
*NAME
Required
No
Length
10
Case
Uppercase

Library Library

Type
*NAME
Required
No
Default
*LIBL
Length
10
Case
Uppercase

Suggested / special values: *LIBL, *CURLIB

MFRTYPMDL Manufacturer type and model

Specifies the manufacturer, type and model of the remote printer, which selects the host print transform parameters.

Type
*CHAR
Required
No
Default
*NONE
Length
10
Case
Uppercase

Suggested / special values: *NONE, *WSCST, *IBM42011, *IBM42021, *IBM42023, *IBM4212990, *IBM4212991, *IBM4212999, *IBM4312, *IBM5327, *IBM5400, *IBM5400-10, *IBM5400-20, *IBM5577

*NONE
No manufacturer type and model is used.
*WSCST
The workstation customizing object given on WSCST supplies the printer definition.

INTNETADR Internet address

Specifies the internet address of the remote system in dotted decimal form. Used when RMTSYS(*INTNETADR) is given.

Type
*CHAR
Required
No
Length
15
Case
Uppercase

WSCST Workstation customizing object

Specifies the workstation customizing object that customizes the host print transform for the remote printer.

Type
*QUAL
Required
No
Default
*NONE
Case
Uppercase

Suggested / special values: *NONE

*NONE
No workstation customizing object is used.
Qualified parts (object, then library; write LIBRARY/OBJECT)

Workstation customizing object Workstation customizing object

Type
*NAME
Required
No
Length
10
Case
Uppercase

Library Library

Type
*NAME
Required
No
Default
*LIBL
Length
10
Case
Uppercase

Suggested / special values: *LIBL, *CURLIB

DLTSPLF Delete file after sending

Specifies whether the spooled file is deleted after it has been sent.

Type
*CHAR
Required
No
Default
*NO
Length
4
Case
Uppercase

Allowed values: *NO, *YES

*NO
The file stays on its output queue.
*YES
The file is deleted after it is sent.

DESTOPT Destination-dependent options

Specifies options that are passed to the remote LPD server as they are.

Type
*CHAR
Required
No
Default
*NONE
Length
255
Case
Uppercase

Suggested / special values: *NONE

*NONE
No destination options are sent.

SEPPAGE Print separator page

Specifies whether the remote system prints a separator page for the file.

Type
*CHAR
Required
No
Default
*NO
Length
4
Case
Uppercase

Allowed values: *NO, *YES

*NO
No separator page is printed.
*YES
A separator page is printed.

Examples

SNDTCPSPLF RMTSYS(*INTNETADR) PRTQ('PDFING') FILE(QPRTLIBL) JOB(*) SPLNBR(*LAST) DESTTYP(*AS400) TRANSFORM(*NO) INTNETADR('192.168.1.10')

Sends the last QPRTLIBL spooled file to printer queue PDFING on the system at 192.168.1.10 without host print transform.

IBM command documentation

Generated from os/cl/catalog/SNDTCPSPLF.json and os/cl/help/SNDTCPSPLF.json.