1 filename unixin '/net/bin/u/leking/sample.txt' encoding=latin1; 2 data _null_; 3 infile unixin; 4 input; 5 put _infile_; 6 run; NOTE: The infile UNIXIN is: File Name=/net/bin/u/leking/sample.txt, Access Permission=-rwxr-xr-x,Number of Links=1, Owner Name=LEKING,Group Name=R@D,File Size=45, Last Modified=Jan 19 2000 This is a test. Another line. End of file.
dd
command reads the InFile parameter or standard input, performs the specified conversion, and then copies the converted data to the OutFile
parameter or standard output. The input block size and output block size can be specified to take advantage of
raw physical I/O.
dd
command performs a fixed-length to
variable-length conversion. Otherwise, it performs a variable-length
to fixed-length conversion. The cbs parameter value determines the
fixed length.
dd
command
reports the number of whole and partial input and output blocks. For
more information about the dd
command, see
the dd
manual page on your system.
dd
command
returns the following exit values:
Item
|
Description
|
0
|
The input file was copied
successfully.
|
>0
|
An error occurred.
|
dd if=text.ascii of=text.ebcdic conv=ebcdic
dd
command converts the ASCII ^ (circumflex) character to an unused EBCDIC character
(9A hexadecimal) and the ASCII ~ (tilde) character to the EBCDIC ^ character
(NOT symbol).
dd
command
as a filter, enter the following:
ls -l | dd conv=ucase
dd
command and cpio
command
in the IBM 9348 Magnetic Tape Unit Model 12 can be improved by changing
the default block size. To change the block size, use the chdev
command
as follows:
chdev -l Device_name -a block_size=32k
iconv
command to convert the encoding of a text file. Use one the following examples of syntax:iconv –f FromCode –t ToCode FileName
iconv –l
iconv
command,
see the iconv
manual page on your system.
iconv
command
returns the following exit values:
Item
|
Description
|
0
|
Input data was successfully
converted.
|
1
|
The specified conversions
are not supported, the input file cannot be opened or read, or there
is a usage-syntax error.
|
2
|
An unusable character
was encountered in the input stream.
|
iconv –f IBM-850 –t ISO8859-1 mail.x400 > mail.local
iconv –f IBM-943 –t fold7 mail.local > mail.fxrojas