Hello,
I am working on unix for the first time.
I have to write a shell script where i want to cut paste from one file to other.
File "1234.abc" is
Here in "03,12345555", 03 indicates line id and 12345555 indicates account number of user. The subsiquent lines are details for account number 12345555 till record "49,12345555"
From next line, details for new account number eg.12347710 starts
My requirement is if i give parameter as 12347710, all records for this accounts should be cut from File "1234.abc" and should be pasted in new file "1234.7710" (ie name of original file and extn is last four digits of parameter)
so new "1234.abc" will be
and "1234.7710" will be
Last edited by Franklin52; 12-09-2010 at 08:05 AM..
Reason: Please use code tags, thank you
hi i am new to shell scripting,
i have been trying to cut columns numbered 1,4 of a file consisiting of 4 columns. Each column is seperated by 2 spaces.
for example:
john 6102097199 tennessee usa
michel 6734590899 texas USA
now, i need to cut the name... (3 Replies)
hi,
I have a file with content like this for an employee:
EmployeeID
101
Day_type, day
vacation,1/2/2009
sick day, 3/2/2009
personal day, 4/5/2009
jury duty day, 5/5/2009
how do I make the result to show:
EmployeeID,Day_type,day
101,vacation,1/2/2009
101,sick day,... (6 Replies)
Hi,
Need a help with shell script. I have to search for a string in one of the file, if match found, copy the line to a new file and delete the line from the exisiting file.
eg:
83510000000000063800000.1800000.1600000.1600000.2400000.1800000.2000000.21... (6 Replies)
I have a file which contains 3 fields separated by tabs example
andrew kid baker
I need to swap kid and baker using cut and paste commands how is this to be done?
Thanks (1 Reply)
I have a file which contains 3 fields separated by tabs example
andrew kid baker
I need to swap kid and baker using cut and paste commands how is this to be done?
Thanks (3 Replies)
Hi,
First of all sincere apologies if I have posted in a wrong section ! Please correct me if I am wrong !
I am very new to UNIX scripting.
Currently my problem is that I have a code file at the location /home/usr/workarea/GeneratedLogs.log :-
Code :-
(Feb 7, 571 7:07:29 AM),... (4 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)
Hello,
I have some problem in cut or paste command for my text data.
Input1.txt :
I use cut command :
cut -d ' ' -f1 Input1.txt > result.txt result.txt :
Then, I use paste command to merge result.txt.
paste -d ' ' result.txt Input1.txt > output.txt output.txt showed :
I use cut... (1 Reply)
Hello ppl
I have a requirement to split (cut in unix) a file (A.txt) which is a pipe delimited file into A1.txt and A2.txt
Now I have to join (paste in unix) this A2.txt with external file A3.txt to form
output file A4.txt which should be CSV (comma separated file) so that third party can... (25 Replies)
Discussion started by: etldev
25 Replies
LEARN ABOUT MOJAVE
encode::cn
Encode::CN(3pm) Perl Programmers Reference Guide Encode::CN(3pm)NAME
Encode::CN - China-based Chinese Encodings
SYNOPSIS
use Encode qw/encode decode/;
$euc_cn = encode("euc-cn", $utf8); # loads Encode::CN implicitly
$utf8 = decode("euc-cn", $euc_cn); # ditto
DESCRIPTION
This module implements China-based Chinese charset encodings. Encodings supported are as follows.
Canonical Alias Description
--------------------------------------------------------------------
euc-cn /euc.*cn$/i EUC (Extended Unix Character)
/cn.*euc$/i
/GB[-_ ]?2312(?:D.*$|$)/i (see below)
gb2312-raw The raw (low-bit) GB2312 character map
gb12345-raw Traditional chinese counterpart to
GB2312 (raw)
iso-ir-165 GB2312 + GB6345 + GB8565 + additions
MacChineseSimp GB2312 + Apple Additions
cp936 Code Page 936, also known as GBK
(Extended GuoBiao)
hz 7-bit escaped GB2312 encoding
--------------------------------------------------------------------
To find how to use this module in detail, see Encode.
NOTES
Due to size concerns, "GB 18030" (an extension to "GBK") is distributed separately on CPAN, under the name Encode::HanExtra. That module
also contains extra Taiwan-based encodings.
BUGS
When you see "charset=gb2312" on mails and web pages, they really mean "euc-cn" encodings. To fix that, "gb2312" is aliased to "euc-cn".
Use "gb2312-raw" when you really mean it.
The ASCII region (0x00-0x7f) is preserved for all encodings, even though this conflicts with mappings by the Unicode Consortium.
SEE ALSO
Encode
perl v5.18.2 2013-11-04 Encode::CN(3pm)