Folks,
Is there a simple way to replace one digit by two digit using sed.
Example,
mydigit1918_2006_8_8_lag1.csv should be
mydigit1918_2006_08_08_lag01.csv.
I tried this way, but doesn't work.
echo mydigit1989_2006_8_8_lag1.csv|sed 's/]/0]/'
Thank you, (5 Replies)
Hi All,
How can i convert a number 24 to 0024
In the same way how can i convert 123 to 0123?
All this has to be done inside a script
Thanks in advance
JS (6 Replies)
I have a var storing date
var=`date`
Now the date is returned as
Mon Feb 2 00:25:48 PST 2009
Is there any way to check the date field alone ("2" in above case) and if its a single digit then add a prefix 0 to it and store the result in same variable "var"
My intention in above case is... (3 Replies)
I want to create new file for START-END
but i know NO 0003/02 only one in file
Ex. Data FILE Data.txt (Data ~1,000,000 Line)
I use Script perl
perl -lne '$/="END";print $_."END" if /0003\/02/' fileOut put script perl
but I want create Out put All No in START-END have NO 0003/02 Please... (8 Replies)
I must design a UNIX script to monitor files whose size is over a threshold of 5 MB in a specific UNIX directory
I meet a problem during the for loop in my script. Some file names contain spaces.
ls -lrt | awk '$5>=5000000 && length($8)==5 {gsub(/ /,"_",$9); print};'
-rw-r--r-- 1 was61 ... (2 Replies)
I need to cut all the Strings in one file and Paste it in the another file in the Specific line by replacing the specific String. For Example
Step 1: From the newfile.txt, i need to copy all the strings
newfile.txt
How are you, I am fine, How is your work
newfle2.txt
Hello david,... (2 Replies)
The perl parser below works as expected assuming the last digit in the NC_ before the . is a single digit.
perl -ne 'next if $. == 1;
if(/.*del(+)ins(+).*NC_0{4}(+).*g\.(+)_(+)/) # indel
{
print join("\t", $3, $4, $5, $1, $2), "\n";
}
' out_position.txt > out1.txt
... (8 Replies)
i have a file with following data.
{
EqName "Tan 1"
....
....
}
{
EqName "Sin 2"
...
...
}
I have to replace the value of EqName to Tan_1 and Sin_2 in file.Can i use sed or awk ?
cat file|grep EqName|awk '{print $2 $3}'|sed -i 's//_/g'
I tried with this but it... (2 Replies)
Discussion started by: Jag02
2 Replies
LEARN ABOUT SUNOS
iconv_ko
iconv_ko(5) File Formats Manual iconv_ko(5)NAME
iconv_ko - code set conversions in Korean (ko) locale
AVAILABILITY
SUNWkleu
DESCRIPTION
The following code set conversions are supported:
Code Set Conversions Supported
Code Symbol TargetCode Symbol
Wansung ko_KR-euc Johap ko_KR-johap92
Wansung ko_KR-euc Packed ko_KR-johap
Wansung ko_KR-euc N-Byte ko_KR-nbyte
Wansung ko_KR-euc ISO-2022-KR ko_KR-iso2022-7
Johap ko_KR-johap92 Wansung ko_KR-euc
Packed ko_KR-johap Wansung ko_KR-euc
N-Byte ko_KR-nbyte Wansung ko_KR-euc
ISO-2022-KR ko_KR-iso2022-7 Wansung ko_KR-euc
The conversions are performed as like following descriptions.
Wansung to Johap and Johap to Wansung
For the conversion between Wansung which is in Korean EUC representation of KS C 5601-1992 and also known as Completion code and Johap
which is described at KS C 5601-1992 Annex 3: Supplementary Code System (2 Byte Johap Code System) and also known as Combination code, all
characters can be mapped if conversion is from Wansung to Johap. However, from Johap to Wansung conversion, certain Hangul characters
which are not in KS C 5601-1992 precompsed character set will not be able to mapped. Such characters will be mapped into underscore charac-
ter (octal value of 137) of KS C 5636. In case of Hanja and special symbol characters, they will follow the mapping rules of Table 3 of
Annex 3 of KS C 5601-1992.
Wansung to Packed and Packed to Wansung
For the conversion between Wansung and Packed which is described at KS C 5601-1987 Annex 3: Supplementary Code System (2 Byte Johap Code
System), all characters except Hanja and special symbol characters can be mapped if conversion is from Wansung to Packed. Such Hanja and
special symbol characters will be mapped into underscore character (octal value 137) of KS C 5636. From Packed to Wansung conversion, cer-
tain Hangul chracters will not be able to mapped since not every Hangul Packed code is representable in Wansung. Such characters will be
mapped into underscore character of KS C 5636.
Wansung to N-Byte and N-Byte to Wansung
For the conversion between Wansung and N-Byte which is described at KS C 5601-1992 Annex 4: 7 Bit Hangul Alphabet codes, all characters
except Hanja and special symbol characters can be mapped. Such Hanja and special symbol characters will be mapped into underscore charac-
ter (octal value 137) of KS C 5636.
Wansung to ISO-2022-KR and ISO-2022-KR to Wansung
For the conversion between Wansung and ISO-2022-KR which is described at RFC 1557: Korean Character Encoding for Internet Messages, all
characters can be mapped.
FILES
/usr/lib/iconv/ko_KR-euc%ko_KR-johap92.so
Shared object for Korean EUC to Johap code conversion
/usr/lib/iconv/ko_KR-euc%ko_KR-johap.so Shared object for Korean EUC to Packed code conversion
/usr/lib/iconv/ko_KR-euc%ko_KR-nbyte.so Shared object for Korean EUC to N-Byte code conversion
/usr/lib/iconv/ko_KR-euc%ko_KR-iso2022-7.so
Shared object for Korean EUC to ISO-2022-KR code conversion
/usr/lib/iconv/ko_KR-johap92%ko_KR-euc.so
Shared object for Johap to Korean EUC code conversion
/usr/lib/iconv/ko_KR-johap%ko_KR-euc.so Shared object for Packed to Korean EUC code conversion
/usr/lib/iconv/ko_KR-nbyte%ko_KR-euc.so Shared object for Johap to Korean EUC code conversion
/usr/lib/iconv/ko_KR-iso2022-7%ko_KR-euc.so
Shared object for ISO-2022-KR to Korean EUC code conversion
SEE ALSO iconv(1), iconv(3), iconv(5)
10 Mar 1995 iconv_ko(5)