SUNWcsu
The iconv command converts the characters or sequences of characters in file from one code set to another and writes the results to standard output. Should no conversion exist for a particular character then it is converted to the underscore ’_’ in the target codeset.
iconv will always convert to or from the ISO 8859-1 Latin alphabet No.1, from or to an ISO 646 ASCII variant codeset for a particular language. The ISO 8859-1 codeset will support the majority of 8 bit codesets. The conversions attempted by iconv accommodate the most commonly used languages.
The following table lists the supported conversions.
Code Set Conversions Supported Code Symbol Target Code Symbol comment ISO 646 646 ISO 8859-1 8859 US ASCII ISO 646de 646de ISO 8859-1 8859 German ISO 646da 646da ISO 8859-1 8859 Danish ISO 646en 646en ISO 8859-1 8859 English ASCII ISO 646es 646es ISO 8859-1 8859 Spanish ISO 646fr 646fr ISO 8859-1 8859 French ISO 646it 646it ISO 8859-1 8859 Italian ISO 646sv 646sv ISO 8859-1 8859 Swedish ISO 8859-1 8859 ISO 646 646 7 bit ASCII ISO 8859-1 8859 ISO 646de 646de German ISO 8859-1 8859 ISO 646da 646da Danish ISO 8859-1 8859 ISO 646en 646en English ASCII ISO 8859-1 8859 ISO 646es 646es Spanish ISO 8859-1 8859 ISO 646fr 646fr French ISO 8859-1 8859 ISO 646it 646it Italian ISO 8859-1 8859 ISO 646sv 646sv Swedish
The conversions are performed according to the tables found on iconv(5) .
The following converts the contents of file mail1 from code set 8859 to 646fr and stores the results in file mail.local.
example% iconv -f 8859 -t 646fr mail1 > mail.local
The following exit values are returned:
Refer to the /usr/share/man/man5/iconv_locale.5 manual page in the Asian localized releases for information on which codeset conversions are supported. For example, the command
% man -s 5 iconv_ja
would display the manual page describing the codeset conversions that are supported for the Japanese locale.
Note that the iconv_locale.5 manual page may not exist in every localized release. Also, the iconv_locale.5 manual page does not exist in the U. S. (non-localized) release.